BookmarkSubscribeRSS Feed
yabwon
Onyx | Level 15

Today we have March 8ht, so its International Women’s Day.

Bart

 

kwiat2024.gif

Code:

%macro kwiat(s,e,b,min=0,max=256,c=constant('pi'));
  %do i = &s. %to &e. %by &b.;
    data have;
      v=0.01;
      w=1;
      c=-1;

      do a=1,2,3,4,5;
        do y = -3*constant('pi') to -2 by 0.1;
          x1 = a*sin(y)/(10/y);
          output;
        end;
      end;
      x0 = .;

      do y = -4*constant('pi') to 0 by 0.1;
        x1 = sin(y)/10;
        output;
      end;
      x1 = .;

      w = &i.;
      do t = &min. to &max. by 0.5;
        c = &c. * sin(t);
        x3 = (v*t+c) * cos(w*t);
        y = (v*t+c) * sin(w*t);
        output;
      end;
      x3 = .;

      do t = 0 to 256 by 0.1;
        c = sin(t);
        w = 1;
        x2 =  - (v*t+c) * cos(w*t) + 0.3;
        w = 2;
        y = (v*t+c) * sin(w*t) - 6.5;
        output;
      end;
    run;

    /*ods graphics / height=1000px width=500px antialias=yes antialiasmax=100000;*/
    title "International Women’s Day 2024";
    proc sgplot data=have noborder noautolegend nowall PAD=0;
      series x=x1 y=y / LINEATTRS=(color=green thickness=8);
      series x=x1 y=y / LINEATTRS=(color=lightgreen thickness=5) transparency=0.5;

      series x=x2 y=y / LINEATTRS=(color=gold thickness=2) transparency=0.2;

      series x=x3 y=y / LINEATTRS=(color=white thickness=6) transparency=0.5;
      series x=x3 y=y / LINEATTRS=(color=pink thickness=4) transparency=0.25;
      series x=x3 y=y / LINEATTRS=(color=purple thickness=2);

      xaxis display=none min=-7 max=7;
      yaxis display=none min=-16 max=7;
    run;
  %end;
%mend kwiat;



ods _all_ close;                       
options papersize=('500 px','1000 px') 
        printerpath=gif 
        animation=start 
        nodate 
        nonumber 
        animloop=YES 
        noanimoverlay 
        animduration=.2;

ods printer file='R:/kwiat2024.gif';

ods graphics on / reset height=1000px width=500px antialias=yes antialiasmax=100000 imagefmt=GIF;

%kwiat(25,125,25,max=362)

options printerpath=gif animation=stop;
ods printer close;
_______________
Polish SAS Users Group: www.polsug.com and communities.sas.com/polsug

"SAS Packages: the way to share" at SGF2020 Proceedings (the latest version), GitHub Repository, and YouTube Video.
Hands-on-Workshop: "Share your code with SAS Packages"
"My First SAS Package: A How-To" at SGF2021 Proceedings

SAS Ballot Ideas: one: SPF in SAS, two, and three
SAS Documentation



sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 0 replies
  • 488 views
  • 7 likes
  • 1 in conversation