03-05-2014 10:24 AM
I am trying to create some calendars using a data set of simple single-day events.
In my data set, the maximum number of "events" per day is 8 and the maximum string length of an event is 22 characters.
Events occur on all days of the week so limiting to weekdays will not help.
When I run Proc Calendar to create my output, it truncates my event entries and leaves some off (directing output to screen).
I have tried setting the linesize and pagesize options, tried setting papersize to legal, tried portrait / landscape and nothing helps.
Plus when I direct my output to PDF it shrinks the calendar to approximately 2/3 of a page wide and tall.
I need to be able to display all events in their entirety - I realize it's probably a simple setting but most of what I do deals with raw data, not making it look pretty, so the output side of SAS is kind of a mystery.
Thanks for any help.
03-05-2014 11:20 AM
It may help us to provide the code you're using.
The PDF issue might be the default font used by the style, but that's a guess.
03-05-2014 11:43 AM
Here's basically what I'm running:
ods pdf file="c:\mypath\caltest.pdf" ;
proc calendar data=cal;
ods pdf close;
I have tried playing with the linesize=, pagesize=, papersize, orientation options but all truncate either the number of events or the width of events. I'm not using any styles - just the default settings.
Here's some sample data without the stuff that would get me fired (all events are only one day dur=1 for all ):
FROM_DATE dur event
11AUG2010 1 2 other codes
11AUG2010 1 205xx Inj
11AUG2010 1 99205
11AUG2010 1 ECG 2 codes
11AUG2010 1 Injection + 1 j drug
11AUG2010 1 PT
11AUG2010 1 UA / Lab
11AUG2010 1 venipuncture
17AUG2010 1 205xx Inj
17AUG2010 1 7 other codes
17AUG2010 1 99214
17AUG2010 1 Injection + 2 j drugs
17AUG2010 1 UA / Lab
17AUG2010 1 venipuncture
24AUG2010 1 205xx Inj
24AUG2010 1 3 other codes
24AUG2010 1 99214
24AUG2010 1 UA / Lab
24AUG2010 1 venipuncture
03-05-2014 11:47 AM
You will need to check with Tech Support. I believe that part of the reason might be that PROC CALENDAR was originally designed for the LISTING window/destination. So it is designed to be MONOSPACE (fixed pitch font) output. I believe that when you use PROC CALENDAR with ODS, that ODS makes an area on the page and inside that area is the "batch" or LISTING output....using a fixed-pitch font and dashes and asterisks and other characters from the FORMCHAR option to make the calendar box. Therefore, I do not think you can impact the PROC CALENDAR output with a STYLE template. But, as I said, you need to check with Tech Support. There are a few procedures that work this way. I think CALENDAR was one, EXPLODE was another, possible PROC PLOT and PROC CHART and a few others. Tech Support could verify whether the style and margin options will have an impact on PDF. The documentation examples show HTML, but if you notice, in the doc, the calendar itself is "unstyled" -- only the title uses the style colors and fonts:
Base SAS(R) 9.4 Procedures Guide, Second Edition (calendar example showing monospace font for calendar and no style)