Non Parametric regression analysis with moderating effect

Moderators: statman, Analyst Techy, andris, Fierce, GerineL, Smash

Stanj

Non Parametric regression analysis with moderating effect

Postby Stanj » Wed Oct 08, 2008 10:18 am

Hi All,

In my ignorance when setting up my theoretical part I drew the following theoretical framework:

Intensity of customer involvement -------------> Product Performance

(with a moderating effect: inverted U shaped: named innovativeness)


Because the univariate analysis showed that the variables deviate from normality I have to conduct a non parametric regression analysis, with an inverted u-shape moderating effect.

Can anyone help me with how to do this?

Kind Regards,

Stan
statman
Administrator
Posts: 2756
Joined: Tue Jun 12, 2007 12:08 pm
Location: Florida, USA

Postby statman » Wed Oct 08, 2008 12:27 pm

Are you talking about nonparametric Linear Regression or any Nonparametric regression model (like kernel or spline smoothing...)?

For general methods, see: Applied Nonparametric Regression, by Wolfgang Hardle

For nonparametric LINEAR regression, Theil's incomplete method, as described in:

http://www.chem.uoa.gr/Applets/AppletTh ... Theil2.htm

If the latter, I came across some syntax awhile back so if this is it let me know & will try to find again
See the note below

NOTE: Please read the Posting Guidelines and always tell us your OS, the SPSS version and information about your study and data!

Statman
Statistical Services
alla_guseva
Posts: 1
Joined: Sun Nov 23, 2008 12:01 pm

Non Parametric regression analysis

Postby alla_guseva » Sun Nov 23, 2008 12:16 pm

Hello
There was a post some time back regarding Non Parametric regression analysis, and a reply by Statman :
For nonparametric LINEAR regression, Theil's incomplete method, as described in: ..... If the latter, I came across some syntax awhile back so if this is it let me know & will try to find again

Could you please share the syntax you mentioned (for non-parametric linear regression)?

Sincerely,
Alla
statman
Administrator
Posts: 2756
Joined: Tue Jun 12, 2007 12:08 pm
Location: Florida, USA

Postby statman » Mon Nov 24, 2008 1:44 pm

Untested by me

Code: Select all


* Sample dataset (replace by your own) *.
DATA LIST FREE/oestriol weight (2 F8.0).
BEGIN DATA
 7 2500 17 3200 19 3400  9 2500 25 3200 18 3500  9 2500
27 3400 17 3600 12 2700 15 3400 18 3700 14 2700 15 3400
 20 3800 16 2700 15 3500 22 4000 16 2400 16 3500 25 3900
14 3000 24 4300 19 3100 16 3000 24 2800 21 3000 16 3100
15 3200 17 3000 16 3200
END DATA.
VAR LABEL oestriol 'Urinary Oestriol (mg/24 h)'
         /weight 'Baby weight at birth (g)'.

MATRIX.
* Variable names: replace by yours (IV goes first, DV last) *.
GET data /VAR=oestriol weight /NAMES=vnames /MISSING=OMIT.
PRINT vnames
 /FORMAT='A8'
 /TITLE='Variable names (X & Y)'.
* Sort cases by IV (ascending) (method by Ristow&Peck)*.
COMPUTE sdata=data.
COMPUTE sdata(GRADE(data(:,1)),:)=data.
* Split data in two halves *.
COMPUTE n=NROW(data).
COMPUTE half=TRUNC(n/2).
COMPUTE low =MAKE(half,2,0).
COMPUTE high=MAKE(half,2,0).
DO IF (half EQ n/2).     /* Even sample size (all data are used) *.
- LOOP i=1 TO half.
-  COMPUTE low(i,:)=sdata(i,:).
- COMPUTE high(i,:)=sdata(half+i,:).
- END LOOP.
ELSE.                    /* Odd sample size (one data point is discarded) *.
- LOOP i=1 TO half.
-  COMPUTE low(i,:)=sdata(i,:).
- COMPUTE high(i,:)=sdata(half+1+i,:).
- END LOOP.
END IF.
RELEASE sdata.
* Compute all slopes (bi) *.
COMPUTE bi=(high(:,2)-low(:,2))/(high(:,1)-low(:,1)).
* Sort all bi and compute their median *.
COMPUTE sbi=bi.
COMPUTE sbi(GRADE(bi))=bi.
DO IF TRUNC(half/2) EQ half/2).  /* Median formula for even samples *.
- COMPUTE lb=sbi(half/2).
- COMPUTE ub=sbi(1+half/2).      /* Median is the average of two values *.
- COMPUTE b=(lmedian+umedian)/2.
ELSE.                            /* Median formula for odd samples *.
- COMPUTE b=sbi((half+1)/2).     /* Median is one value of the sample *.
END IF.
* Compute the intercept *.
COMPUTE ai=data(:,2)-b&*data(:,1).
* Sort all ai and compute their median *.
COMPUTE sai=ai.
COMPUTE sai(GRADE(ai))=ai.
DO IF TRUNC(half/2) EQ half/2).  /* Median formula for even samples *.
- COMPUTE la=sai(half/2).
- COMPUTE ua=sai(1+half/2).      /* Median is the average of two values *.
- COMPUTE a=(lmedian+umedian)/2.
ELSE.                            /* Median formula for odd samples *.
- COMPUTE a=sai((half+1)/2).     /* Median is one value of the sample *.
END IF.
PRINT {a;b}
 /FORMAT='F8.1'
 /RLABEL='A=','B='
 /TITLE='Non parametric linear regression coefficients:'.
 * Saving predicted & residuals to active dataset *.
COMPUTE pred=a+b*data(:,1).
COMPUTE res=data(:,2)-pred.
COMPUTE newdata={pred,res}.
COMPUTE newnames={'pre_np','res_np'}.
SAVE newdata /OUTFILE='c:\Temp\Predicted&Residual.sav'/NAMES=newnames.
END MATRIX.
MATCH FILES /FILE=* /FILE='c:\Temp\Predicted&Residual.sav'.
EXECUTE.

* Graph observed and predicted *.
GRAPH
  /SCATTERPLOT(OVERLAY)=weight pre_np WITH oestriol
  /MISSING=LISTWISE .

Who is online

Users browsing this forum: No registered users and 1 guest

cron