BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
CherylMac
Obsidian | Level 7

Would someone please demonstrate (or point to a sample program) for the use of blockindex with a blockplot graph? My blockplot code is working but I need to associate specific, unchanging colors with my three blockplot values. Usually I can find sample code for most SAS features but I am coming up empty with this one. I know I need the filltype and blockindex options on my blockplot statement but I don't know how to create the color index. I would appreciate any help. Thanks!

 

Cheryl

 

[SAS 9.4 TS Level 1M3 on Win32_7PRO platform]

1 ACCEPTED SOLUTION

Accepted Solutions
Jay54
Meteorite | Level 14

You can use BLOCKINDEX=column option where the column contains the index numbers 1-12 that indicate which of the style group elements are used for each block.  FILLTYPE should be Multicolor.

View solution in original post

3 REPLIES 3
Jay54
Meteorite | Level 14

You can use BLOCKINDEX=column option where the column contains the index numbers 1-12 that indicate which of the style group elements are used for each block.  FILLTYPE should be Multicolor.

CherylMac
Obsidian | Level 7

Thanks for your reply. If I understand you correctly, I only need to add a new numeric column (1,2,3) to my data table then put the name of that column equal to BLOCKINDEX. The number should match the color of the style group element I want to use for each value. Is that correct?

 

No wonder I couldn't find a code example! I will give this a try and report back.

CherylMac
Obsidian | Level 7

Thank you Sanjay. Your explanation helped me understand what I needed to do.

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
  • 3 replies
  • 1239 views
  • 0 likes
  • 2 in conversation