tags:

views:

135

answers:

2

Hi all

(First, I am a SAS newbie, though an experienced programmer. I have googled a little for this, I promise...)

I would like to automate some data analysis processes in population estimation, which would take a bunch of csv data files and some shapefiles as the beginning, do stuff to them (including some geographic intersections to get appropriate FIPS codes and the like), make pretty postscript tables, surround the tables with text, and output the final InDesign file that is ready to ship to a customer after a quick QA on a windows desktop.

I want all my tweaking to be done in the code, rather than by hand; so if a border needs to be switched from 1 point to .5 point, I want to write code to do this, not open the document and do it by hand.

Does anyone have a skeletal recipe or a link for this? If SAS can't do it, I don't know what can...

EDITED 2009-10-21: Sorry for the vagueness of the question, but I don't have any more specifics yet. This will be my learning SAS project, so I hope to have more specific questions soon. I will try stitching something together with the procs described below.

Tx! -W

P.S. If someone could tell me how to mark a question "answered" here too, I would appreciate it ;)

+1  A: 

Robert Allison has a large and fantastic collection of examples using SAS/Graph that include, among other things, geocoding locations, drill-down, dashboards, etc. SAS code for each example is shown as well so you can find something similar to what you want your output to look like and tweak his examples to fit your needs. If you are not familiar with the SAS macro facility yet, you will definitely want to learn the basics to make your life much easier. CSV files can be read into SAS directly with a data step or with the import procedure. Search through the SAS-L newsgroup as well as it has been around for years and someone has likely already asked whatever issue you might be facing.

In general, the more specific you can make your question here, the more helpful we can be.

fscmj
+1  A: 

The SAS System is a very powerful tool. If you've got structured information ("data") in files or DBMS's, chances are very good that you can import your information into the SAS System, and produce the output you need.

  • SAS can import CSV files using the PROC IMPORT procedure or the INPUT statement
  • SAS can import shapefiles using the PROC MAPIMPORT procedure
  • SAS can "do stuff" to data using the DATA step and PROC steps. The PROC SQL procedure enables you to run SQL statements in SAS. Look these up yourself at http://sas.com .
  • SAS can produce PostScript (PS) output using the Ouput Delivery System (ODS)
  • SAS ODS output can be defined ("tweaked") using the PROC TEMPLATE procedure, and directly in the ODS statement

The very general nature of your question only allows a general answer like this.

SAS has the ability to handle the types of components that your question contains, so the SAS system can probably help you complete your task.

Good luck with your further investigations!

BTW. I don't work for SAS Institute, but I've been using the SAS System in my daily job for over 10 years.

Martin Bøgelund