<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Fun With SAS ODS Graphics: Super Bowl LIX, Mahomes vs. Hurts II in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Fun-With-SAS-ODS-Graphics-Super-Bowl-LIX-Mahomes-vs-Hurts-II/m-p/958761#M374170</link>
    <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SuperBowl2025MahomeaHurts.png" style="width: 993px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/104501iBE277F71C414B79F/image-size/large?v=v2&amp;amp;px=999" role="button" title="SuperBowl2025MahomeaHurts.png" alt="SuperBowl2025MahomeaHurts.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Kansas City Chiefs' &lt;A href="https://www.nfl.com/players/patrick-mahomes/stats/" target="_self"&gt;Patrick Mahomes&lt;/A&gt; will match up against the Philadelphia Eagles' &lt;A href="https://www.nfl.com/players/jalen-hurts/stats/" target="_self"&gt;Jalen Hurts&lt;/A&gt; on Sunday in &lt;A href="https://en.wikipedia.org/wiki/Super_Bowl_LIX" target="_self"&gt;Super Bowl LIX&lt;/A&gt;, a rematch of &lt;A href="https://en.wikipedia.org/wiki/Super_Bowl_LVII" target="_self"&gt;Super Bowl LVII&lt;/A&gt; (which KC won). Used a &lt;A href="https://communities.sas.com/t5/Graphics-Programming/Fun-With-SAS-ODS-Graphics-Super-Bowl-LVII-QB-Boxplot-Tale-of-the/td-p/858197" target="_self"&gt;SAS ODS Graphics boxplot&lt;/A&gt; to compare the two quarterbacks' performance two years ago, so this time here's a simple scatter plot comparison of the pair's passing yardages and completion percentages for the 2024-2025 regular season games. Go [&lt;EM&gt;your team here&lt;/EM&gt;]!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;* Fun With SAS ODS Graphics: Super Bowl LIX, Mahomes vs. Hurts II;
                                      * Read in NFL.com quarterback data from Excel sheets and merge;
proc import file='/home/ted.conway/MahomesHurts2024.xlsx' out=mahomes dbms=xlsx replace; sheet="Mahomes";
proc import file='/home/ted.conway/MahomesHurts2024.xlsx' out=hurts dbms=xlsx replace; sheet="Hurts";

proc sql;                             * Merge data, compute completion %, filter out games if which they played little/none;
create table mahomeshurts as 
select 'Mahomes' as QB, yds, comp/att as comp_pct from Mahomes where att&amp;gt;=5 union all
select 'Hurts' as QB, yds, comp/att as comp_pct from Hurts where att&amp;gt;=5;

data myattrmap;                       * Assign marker images to quarterbacks (MS-Word football icons in team color);
input ID $ value $ markersymbol $;
datalines;
myid Mahomes chiefs
myid Hurts eagles
;  
%SGANNO;                              * Create file used to annotate chart with NFL.com potos of Mahomes/Hurts using SAS-provided macros;         
data qbpics;
%SGIMAGE (image="/home/ted.conway/mahomes2025.png",drawspace="DATAVALUE",x1=.56,y1space="LAYOUTPERCENT",y1=0,height=12,heightunit="percent",anchor="BOTTOM"); * Mahomes (bottom left);
%SGIMAGE (image="/home/ted.conway/hurts2025.png",drawspace="DATAVALUE",x1=.74,y1space="LAYOUTPERCENT",y1=0,height=12,heightunit="percent",anchor="BOTTOM"); * Hurts (bottom right);
                                      * Generate a scatter chart of completion % vs yards for each game;
ods graphics / reset antialias height=7.5in width=7.5in border=off imagefmt=svg;
proc sgplot data=mahomeshurts nowall noborder dattrmap=myattrmap sganno=qbpics subpixel; * Map quarterbacks to their football icons and display their photos;
inset 'SUPER BOWL LIX' '   QB MATCHUP' / border textattrs=(color=white weight=bold size=14pt) position=top; * Chart title;
symbolimage name=chiefs image="/home/ted.conway/chiefs2.png"; * Kansas City Chiefs team-colored MS-Word football icon;
symbolimage name=eagles image="/home/ted.conway/eagles2.png"; * Philadelphia Eagles team-colored MS-Word football icon;
styleattrs backcolor=cxbad8bc;         * Pastel greenish-background;
scatter x=comp_pct y=yds / group=qb markerattrs=(size=24pt) attrid=myid; * Scatter chart of completion percentage X yards X QB;
label yds="Passing Yards (Regular Season Games With 5+ Attempts)" comp_pct="Completion Percentage"; * x/y-axis lables;
format comp_pct percent5.1;            * Format completion percentage;
keylegend / title="" noopaque valueattrs=(color=white weight=bold); * Chart legend options;
xaxis display=(noticks noline) grid labelattrs=(color=white weight=bold) valueattrs=(color=white weight=bold) labelattrs=(color=white weight=bold); * x-axis options;
yaxis display=(noticks noline) grid labelattrs=(color=white weight=bold) valueattrs=(color=white weight=bold) labelattrs=(color=white weight=bold); * y-axis ooptions;&lt;/CODE&gt;&amp;nbsp;&lt;/PRE&gt;</description>
    <pubDate>Sat, 08 Feb 2025 19:39:13 GMT</pubDate>
    <dc:creator>tc</dc:creator>
    <dc:date>2025-02-08T19:39:13Z</dc:date>
    <item>
      <title>Fun With SAS ODS Graphics: Super Bowl LIX, Mahomes vs. Hurts II</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Fun-With-SAS-ODS-Graphics-Super-Bowl-LIX-Mahomes-vs-Hurts-II/m-p/958761#M374170</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SuperBowl2025MahomeaHurts.png" style="width: 993px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/104501iBE277F71C414B79F/image-size/large?v=v2&amp;amp;px=999" role="button" title="SuperBowl2025MahomeaHurts.png" alt="SuperBowl2025MahomeaHurts.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Kansas City Chiefs' &lt;A href="https://www.nfl.com/players/patrick-mahomes/stats/" target="_self"&gt;Patrick Mahomes&lt;/A&gt; will match up against the Philadelphia Eagles' &lt;A href="https://www.nfl.com/players/jalen-hurts/stats/" target="_self"&gt;Jalen Hurts&lt;/A&gt; on Sunday in &lt;A href="https://en.wikipedia.org/wiki/Super_Bowl_LIX" target="_self"&gt;Super Bowl LIX&lt;/A&gt;, a rematch of &lt;A href="https://en.wikipedia.org/wiki/Super_Bowl_LVII" target="_self"&gt;Super Bowl LVII&lt;/A&gt; (which KC won). Used a &lt;A href="https://communities.sas.com/t5/Graphics-Programming/Fun-With-SAS-ODS-Graphics-Super-Bowl-LVII-QB-Boxplot-Tale-of-the/td-p/858197" target="_self"&gt;SAS ODS Graphics boxplot&lt;/A&gt; to compare the two quarterbacks' performance two years ago, so this time here's a simple scatter plot comparison of the pair's passing yardages and completion percentages for the 2024-2025 regular season games. Go [&lt;EM&gt;your team here&lt;/EM&gt;]!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;* Fun With SAS ODS Graphics: Super Bowl LIX, Mahomes vs. Hurts II;
                                      * Read in NFL.com quarterback data from Excel sheets and merge;
proc import file='/home/ted.conway/MahomesHurts2024.xlsx' out=mahomes dbms=xlsx replace; sheet="Mahomes";
proc import file='/home/ted.conway/MahomesHurts2024.xlsx' out=hurts dbms=xlsx replace; sheet="Hurts";

proc sql;                             * Merge data, compute completion %, filter out games if which they played little/none;
create table mahomeshurts as 
select 'Mahomes' as QB, yds, comp/att as comp_pct from Mahomes where att&amp;gt;=5 union all
select 'Hurts' as QB, yds, comp/att as comp_pct from Hurts where att&amp;gt;=5;

data myattrmap;                       * Assign marker images to quarterbacks (MS-Word football icons in team color);
input ID $ value $ markersymbol $;
datalines;
myid Mahomes chiefs
myid Hurts eagles
;  
%SGANNO;                              * Create file used to annotate chart with NFL.com potos of Mahomes/Hurts using SAS-provided macros;         
data qbpics;
%SGIMAGE (image="/home/ted.conway/mahomes2025.png",drawspace="DATAVALUE",x1=.56,y1space="LAYOUTPERCENT",y1=0,height=12,heightunit="percent",anchor="BOTTOM"); * Mahomes (bottom left);
%SGIMAGE (image="/home/ted.conway/hurts2025.png",drawspace="DATAVALUE",x1=.74,y1space="LAYOUTPERCENT",y1=0,height=12,heightunit="percent",anchor="BOTTOM"); * Hurts (bottom right);
                                      * Generate a scatter chart of completion % vs yards for each game;
ods graphics / reset antialias height=7.5in width=7.5in border=off imagefmt=svg;
proc sgplot data=mahomeshurts nowall noborder dattrmap=myattrmap sganno=qbpics subpixel; * Map quarterbacks to their football icons and display their photos;
inset 'SUPER BOWL LIX' '   QB MATCHUP' / border textattrs=(color=white weight=bold size=14pt) position=top; * Chart title;
symbolimage name=chiefs image="/home/ted.conway/chiefs2.png"; * Kansas City Chiefs team-colored MS-Word football icon;
symbolimage name=eagles image="/home/ted.conway/eagles2.png"; * Philadelphia Eagles team-colored MS-Word football icon;
styleattrs backcolor=cxbad8bc;         * Pastel greenish-background;
scatter x=comp_pct y=yds / group=qb markerattrs=(size=24pt) attrid=myid; * Scatter chart of completion percentage X yards X QB;
label yds="Passing Yards (Regular Season Games With 5+ Attempts)" comp_pct="Completion Percentage"; * x/y-axis lables;
format comp_pct percent5.1;            * Format completion percentage;
keylegend / title="" noopaque valueattrs=(color=white weight=bold); * Chart legend options;
xaxis display=(noticks noline) grid labelattrs=(color=white weight=bold) valueattrs=(color=white weight=bold) labelattrs=(color=white weight=bold); * x-axis options;
yaxis display=(noticks noline) grid labelattrs=(color=white weight=bold) valueattrs=(color=white weight=bold) labelattrs=(color=white weight=bold); * y-axis ooptions;&lt;/CODE&gt;&amp;nbsp;&lt;/PRE&gt;</description>
      <pubDate>Sat, 08 Feb 2025 19:39:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Fun-With-SAS-ODS-Graphics-Super-Bowl-LIX-Mahomes-vs-Hurts-II/m-p/958761#M374170</guid>
      <dc:creator>tc</dc:creator>
      <dc:date>2025-02-08T19:39:13Z</dc:date>
    </item>
  </channel>
</rss>

