codyevers / envisionr

EnvisionR is a package for assembling Envision delta array output into vector data cubes and then viewing that data using a basic GIS interface.
MIT License
0 stars 0 forks source link

exporting 3 numeric variables as character #7

Open bartj77 opened 3 months ago

bartj77 commented 3 months ago

Two issues: first is that the firsst column, which I believe is your FID has not name. I can fix in SAS but you may want to elimiate from download or rename if easier.

Second issue more problematic is that as you'll see below the first variable, as well as idu, and year have " " around the values, defining them as characters. Can you find a way to remove the quotes. I'm working on SAS code to make the conversion but so far it appears to require an array statement that goes through each line of data for each variable and that sounds both time consuming and (at least in my mind) an unecessary risk.

Here's the first lines of a .csv file exported via EnvisionR

"","idu","year","LULC_A","LULC_B","VEGCLASS","DISTURB","VARIANT","FUELMODEL","TIV","TSD","PFLAMELEN","FlameLen","FIREWISE","Policy","ZONE","WUI","UGB","N_DU","NEW_DU","CoverType","SIZE","CANOPY","LAYERS","A2rxn","SocialCap","SN_React","OUTREACH","FireRisk" "1","8","2019",2,95,8406420,21,1,165,0,3,0,0,0,-99,10,0,NA,0,0,840,6,4,2,0,-99,0,0,0 "2","9","2019",5,40,4358320,21,1,165,0,3,0,0,0,-99,10,0,NA,0,0,435,8,3,2,0,-99,0,0,0 "3","10","2019",5,40,4358320,21,1,165,0,3,0,0,0,-99,10,0,NA,0,0,435,8,3,2,0,-99,0,0,0 "4","11","2019",2,95,8406420,21,1,165,0,3,0,0,0,-99,10,0,NA,0,0,840,6,4,2,0,-99,0,0,0 "5","15","2019",5,40,4358320,51,1,165,0,98,0,0,0,-99,10,0,NA,0,0,435,8,3,2,0,-99,0,0,0