09-01-2015
AllenMcDowell
SAS Employee
Member since
11-16-2012
- 6 Posts
- 0 Likes Given
- 0 Solutions
- 8 Likes Received
-
Latest posts by AllenMcDowell
Subject Views Posted 23307 11-29-2012 03:07 PM 3457 11-29-2012 02:25 PM 23309 11-29-2012 01:34 PM 23309 11-29-2012 11:42 AM 2446 11-16-2012 10:57 AM 7175 11-16-2012 10:44 AM -
Activity Feed for AllenMcDowell
- Got a Like for Re: Compare two medians. 01-01-2021 06:41 AM
- Got a Like for Re: Compare two medians. 07-08-2016 04:44 PM
- Got a Like for Re: Compare two medians. 09-01-2015 04:24 AM
- Got a Like for Re: What SAS procedures are suitable for inpatient workload prediction modeling?. 09-01-2015 04:24 AM
- Posted Re: Compare two medians on Statistical Procedures. 11-29-2012 03:07 PM
- Posted Re: How to calculate pseudo R-Squared in proc GAM? on Statistical Procedures. 11-29-2012 02:25 PM
- Posted Re: Compare two medians on Statistical Procedures. 11-29-2012 01:34 PM
- Posted Re: Compare two medians on Statistical Procedures. 11-29-2012 11:42 AM
- Posted Re: What SAS procedures are suitable for inpatient workload prediction modeling? on Statistical Procedures. 11-16-2012 10:57 AM
- Posted Re: Spearman correlation with complex survey data on Statistical Procedures. 11-16-2012 10:44 AM
-
My Liked Posts
Subject Likes Posted 5 11-29-2012 11:42 AM 3 11-16-2012 10:57 AM
11-29-2012
03:07 PM
Sorry, wrong link. try this one: http://support.sas.com/documentation/cdl/en/statug/65328/HTML/default/viewer.htm#statug_qreg_details13.htm or look at the Details section and select the "Linear Test" entry.
... View more
11-29-2012
02:25 PM
One possibility is discussed in Cameron and Trevedi's "Regression Analysis of Count Data" which describes the deviance as the GLM generalization of the sum of squares. They refer to two papers by Cameron and Windmeijer where a pseudo-R-squared is proposed based on a decomposition of the deviance. In essence, the proposal is to use R2 = 1-(D(intercept-only-model)/D(full-model)). I would recommend reviewing the original papers to verify that the interpretation is appropriate for your particular model before using the result.
... View more
11-29-2012
01:34 PM
The mathematical details of the Wald test are provided at: http://support.sas.com/documentation/cdl/en/statug/65328/HTML/default/viewer.htm#statug_qreg_syntax11.htm You can also perform a likelihood ratio test by specifying the LR option in the TEST statement; the mathematical details are provided on this same page.
... View more
11-29-2012
11:42 AM
5 Likes
You can use PROC QUANTREG. Suppose you have two variables, y1 and y2, that potentially have different medians. Create a new variable y that is just y1 stacked on top of y2, and create a dummy variable x that has a value of 0 if an observation is from y1 and a value of 1 if an observation is from y2. Now you can use QUANTREG to estimate the median conditional on the value of x. The TEST statement performs a WALD test of whether the effect of x is significantly different from 0. Here is a sample program that demonstrates: data one; call streaminit(736283); do i = 1 to 100; if i<51 then y=rand('NORMAL',0,1); if i<51 then x=0; if i>=51 then y=rand('NORMAL',1,1); if i>=51 then x=1; output; end; run; proc quantreg data=one; class x; model y=x; test x; run; The resulting Wald test statistic is 13.2403, the p-value is 0.0003.
... View more
11-16-2012
10:57 AM
3 Likes
You might consider using the ADAPTIVEREG procedure (it is new in SAS/STAT 12.1). It fits adaptive regression splines which can be useful if the relationship between the response variable and the covariates is more complex than a simple linear effect but you don't know exactly what that relationship is.
... View more
11-16-2012
10:44 AM
Spearman correlations are equivalent to Pearson correlations between the ranks of two variables and Pearson correlations are functions of totals. Therefore, you can estimate Spearman correlations using PROC SURVEYMEANS and a little programming. The method is described in the book "Model Assisted Survey Sampling" by Sardal, Swensson and Wretman. The essential formula that you will need for correlations is found in exercise 13.1. There are also two Web Examples available at support.sas.com that demonstrate this method. The Web Examples demonstrate how to estimate the variance of a variable and the standard deviation of a variable; correlations are just an extension of the same idea. http://support.sas.com/rnd/app/examples/stat/SurveyVariance/new_example/index.html http://support.sas.com/rnd/app/examples/stat/SurveyStdDev/new_example/index.html
... View more