Categories

Category: SAS

The theme for SAS Global Forum 2017 was Data Knows No Boundaries, and this is so true, that Rock ‘n’ Roller Coaster Starring Aerosmith ride, that I am pictured in above goes from 0 to 60 MPH in 2.8 seconds! No limits!

What particularly moved me about this conference was the GatherIQ initiative. We learned how each one of us can help either by using our analytical skills or just networking skills when crises happens by just interacting with the GatherIQ app or sharing the details of the crisis. It was a fundamental reminder that the world is bigger than us, and we can do so much good in the world, and support others. It’s quite similar to the DataKind project.

At the conference I gave two 45 minutes hands-on workshops on Graph Template Language (GTL). Part A was an introduction to GTL and Part B showed more of the advanced functions of GTL. Sanjay Matange’s presentation on Decorative Infographs using SAS was really impressive. He shows how you can use the SYMBOLIMAGE statement to produce interesting graphics.

Of course, the reason why everybody comes to the SGF is for the kickback party 😉 This year’s kickback party was the best ever! We obtained entry to Disney World Hollywood Studios and so for 3 hours we were able to exclusively go on the rides, get free photos on the rides, meet disney characters, and get free Mickey Mouse ice cream lol. Also food and drinks were included. And the party was phenomenal. The DJ was so entertaining, and everyone was dancing! This was the best ever! Well done to everyone who organised this!! 🙂 I’m looking forward to the SGF in Colorado next year!

A wealth of useful information relating to the theory of graphics took place on the morning of Day 1. Jenny Freeman from Leeds University presented on Good Practices in Graphics Design. Andreas Krause from Actelion Pharmaceuticals presented on Graphics of Clinical Data: the good, the bad, and the ugly. Ian Cox from JMP at SAS presented on Make it Easy: exploring data with SAS JMP.

In the afternoon of Day 1, Phillip Holland from Holland Numerics, gave an Introduction to SG Procedures and Graphics Template Language (GTL). I learned many useful tips in Phils presentation and at the end of his presentation, I felt it was necessary to purchase his book Power User’s Guide to Graph Template Language.

On Day 2 of the course, I presented the Hands on SAS Graphics Course section. The “Hands on” entailed me showing and describing how the SAS code (typically in version 9.3) can be used to produce the desired output. There was also a fun impromptu section were the participants and I had to figure out the SAS code that Dan Heath and Sanjay Matange used to produce their outputs in the Graphic Samples Output Gallery.

The code that was used in the Hands On SAS Graphics section can be accessed here. The datasets that were used in the presentation can be accessed here. Finally, the presentation can be accessed here.

A few days ago I was asked how to change the fill color of the histogram bars to light green when using Proc UNIVARIATE. The person did try to use the cfill option, however this does not work with ods graphics. They also created a template and specified the color green. However they wanted light green. In the end they produced this graph.

The above graph is a really good attempt actually and they decided to contact me because they discovered the SAS 9.2 Graphics Course on line which I created and gave a few years ago.

I had a really good time at PharmaSUG China 2013. The only thing was I had a really hard time attending the conference! For some reason I didn’t think I needed to have a visa to gain entry into Shanghai, and only found out after I reached Heathrow Airport. At first I was told that I would have to rebook the flight again in at least 4 days! I replied “the conference would be over by then though”.

After further enquiries I found out that I could go to Hong Kong and obtain a Chinese visa from there within “4 hours”. So I persevered on, and was on my way to Hong Kong, which was an amazing place and well worth the visit! Unfortunately instead of 4 hours for the visa I had to wait 24 hours in the end, and I’m very grateful for Leo Li, Margaret Hung and James Wu for rearranging the presentation I was giving from Friday 6 September 2013 to the day after.

I left the conference really intrigued after hearing the last presentation at the conference which was a panel discussion. This entailed the likes of Art Carpenter, Eckhard Pecker, Eric Deng, Sy Truong, Tracey Turschman and Zibhao Zhang answering some really interesting industry topics. Such as how do they see the future for SAS Programmers, and what will SAS Programmers have to learn? This panel was moderated exceptionally well by Yanyun Shen, and the main things I picked up was that SAS Programmers in the pharmaceutical industry should be employable for a long while. There is so much data out there, and China especially has a younger marker than the West and therefore, more businesses are going to be coming to China. To be a proficient SAS Programmer we will need to be flexible and not just rely on “One Procedure” to see us through to retirement. We should be learning other procedures, and it is even better for us if we can learn how to program those “Push a button” macros. Furthermore it will be useful for us to learn other languages such as R and XML; More and more data is on the web.

Finally when the conference closed, I found out that I won a prize! A prize! This is the first time I have ever one a prize, and that means my conference fees for PharmaSUG China 2014 which will be held in Beijing, will be paid for!

Here is some GTL code to produce a Waterfall Plot for % Change in Tumor Size from baseline at Visit 2 coloured by group using SAS 9.2.

The figure below does not seem so advance at first howerver, there are a lot of things going on. Firstly the x-axis is ordered by decreasing % change from baseline. Secondly, the subjects are coloured by another variable (Group), and thirdly the percentage changes are shown on top of or below the bar charts. Enjoy!

If you’re anything like me, I have been keeping up with the advancements of SAS Graphics by Googling SAS Global Forum (SGF), SGPLOT, and Graphics etc. and beside either typing Sanjay Matange or Dan’s Heath name. As a consequence I’ve got lots of Dan’s and Sanjay’s SGF Paper as my favorites, and inevitably have become quite good at creating Graphics 🙂

This book is the end of storing multiple graphical favorites, searching the internet for help, and wondering how to plot good quality graphs with ease! This book is mostly for SAS 9.2 users and goes through the basics of the “new” SG Procedures step by step really well. It shows you how to create nice single cell plots, and describes plot types that can be overlaid and go together, such as a scatterplot and a regression line. It also shows you how to produce paneled plots (multiple plots on one page) which is a well sought after plot, amongst other things. This book touches on the new graphical options in SAS 9.3 and touches on the more advanced techniques, such as attribute maps, which is a really neat way to plot grouped data exactly how you want it, regardless of any missing groups.

I liked that there were specific plot templates based on the business you were in. I found the Health and Life Sciences Chapter really helpful, which showed how to create Forest plots with Summary Statistics and Adverse Events Timeline graphs. Towards the end of the book it gave details on the graph image types that were available, and the pros on cons of each. This was great as it has been an increasing subject of interest.

The only downsides of this book is I would have liked it to also have talked about the DISCRETEOFFSET option in terms of Jittering plots at the lowest level (such as Subject ID) too, and talked more about SGRender and Graph Template Language (GTL). However with regards to talking more about GTL, this is based on the knowledge I know the authors have on the subject and I can imagine the difficulty in actually incorporating GTL as it is a huge subject and there is a steeper learning curve than learning SGPLOT, SGPANEL and SGSCATTER which this book is focused on too.

I recommend this book for anyone that wants to learn the basics and foundations of producing, nice publication ready graphics easily in SAS 9.2 or 9.3 or for any other intermediate or advanced graphical user that would like to sharpen their graphical skills.

Outside of my work environment, I am a big user of the gym! I have been tracking my Flat Bench Press Statistics since August, and have now thought of a few good ways to plot my progress.

The graph below shows the maximum weight I bench pressed within my workouts, and I’ve gone from 90kg to 120kg in 3 months!

Please click on the image to make it clearer!

Maximum Weight I Bench Pressed within my workouts

Another way to look at my progress is to include the average weights I bench pressed. This is done by using the Band Statement in SGPLOT.

Average and Maximum Weight Range I Bench Pressed

It’s also good to see the actual amount of Reps and Sets that were done at each weight throughout the weeks! This is demonstrated with SGPANEL. You can see that in August I was bench pressing around 7 reps maximum of 90kg, and within a few months (Novemeber) this went up to 7 reps of 100kg! I’m very proud of this! One of my targets are to do 10 reps of 100kg (2 plates), and then another target is to do 1 rep of 140kg (3 plates)