Can you guide me the connection setup guide for GoogleBIG Query from SAS9.4 M8 on RHEL?.
We do have license to SAS Access Interface to BigQuery, making direct connection using libname statement through credentail file using BigQuery engine is not working even though we have a 443 port enabled from the server.
... View more
Tried using the following code and obtained the error message below. Would greatly appreciate any insight into how to correct code/what I am doing wrong. variables BMI and age are continuous, gender is binary. Code: proc mcmc data=pdata outpost=pdata seed=1234 nmc=20000; ods select PostSumInt; parms beta0 0 beta1 0 beta2 0 beta3 0 s2 1; prior s2 ~ igamma(0.01, s=0.01); prior beta: ~ general(0); w = beta0 + beta1*bmi + beta2*age + beta3*gender; random delta ~ normal(w, var=100) subject=childid; pi = logistic(delta); model sick ~ binomial(p=pi); run; ERROR: A hyperparameter of the random effect delta changed value in observation 2. The hyperparameter is a function of the data set variable bmi, which must remain constant within subjects.
... View more
Hello, I am getting the following error messages when trying to merge two datasets. One of the datasets I am getting from a csv file, so maybe the issue could be there? I was trying to specify the length of the PID variable for the redcap_sort dataset from the redcap one, which is the one we got from the csv file. However, I keep getting messages that the variable has multiple lengths and it keeps truncating the data. Any PID after 999 gets shortened. So 1000 and 1001 become 100, 1010 becomes 101, etc. Any help or a nudge in the right direction would be greatly appreciated, thank you so much. Edit: The programming with the csv file already has: data work.redcap; %let _EFIERR_ = 0;
infile &csv_file delimiter = ',' MISSOVER DSD lrecl=32767 firstobs=1 ;
informat pid $500. ;
informat pid_ini $500. ; and the code for format: format pid $500. ; It has this for all the variables. I thought the above code would make it so that the variables would have that limit of 500 characters?
... View more
Hi, How can I obtain the p-value of the ADF test, which uses AIC or BIC to determine the lag for residuals, in order to test the stationarity of the residuals of a linear regression model? I have tried proc arima but don’t know how to set the AIC/BIC option for lag length. The input data and my code: data df;
input month dep ind1 ind2 ind3;
cards;
1 -4.66344 0.5337595 1.533904 -0.1824561
2 -4.27203 0.5371667 1.638746 -0.2840759
3 -4.31303 0.5187737 1.708084 -0.208212
4 -3.46126 0.501581 1.773411 0.7434088
5 -3.10906 0.5024615 -0.7010086 0.4447428
6 -2.83321 0.50575 0.7289928 0.2619768
7 -2.74544 0.4943883 0.7419567 0.7679318
8 -3.30505 0.4825768 0.7544792 0.273685
9 -3.28185 0.468799 0.9924411 -0.1544852
10 -3.54578 0.4705212 1.133435 0.6179188
;
run;
proc reg
data=df;
model dep = ind1 ind2 ind3 ;
OUTPUT OUT=model_output_c predicted= pred residual=resid;
run;
proc arima data=model_output_c;
identify var=resid STATIONARITY=(ADF) ;
run;
Thank you!
... View more
I'm trying to follow the code on this site Test for the equality of two proportions in SAS - The DO Loop for the section called A chi-square test for association in SAS. I basically need to compare the proportion in one area which was tested for something to the proportion in another area which was tested and see if they are significantly different proportions, but I can't get the code to work right. I get this error:
NOTE: Invalid data for N in line 79 1-6.
RULE: ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0
79 CountyB Yes 71
Group=CountyA Seq=No N=. _ERROR_=1 _N_=2
NOTE: SAS went to a new line when INPUT statement reached past the end of a line.
My full code is:
data underfive; length Group $15 Test $3; input Group Test N; datalines; CountyA Yes 55 CountyA No 45027 CountyB Yes 71 CountyB No 311726;
Once I had that in I figured I would run this:
proc freq data=underfive order=data; weight N; tables Group*Test/chisq; run;
... View more