I have what is a simple question. Is there a way to save the residual
mean square is a file like one can do with CORB or COVB specification in the regression procedure? By residual mean square I mean, for a simple linear regression model, ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the actual y value. I am running a regression procedure in a loop in a DEFINE and need to be able to uniquely identify the files that have the residual mean square (each with a name like concat(RME,!i), where !i is the DEFINE loop variable). This can be done with the CORB and COVB specifications. Stan ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
Administrator
|
Look into OMS. An alternative is to roll your own with MATRIX.
Stan Gorodenski wrote > I have what is a simple question. Is there a way to save the residual > mean square is a file like one can do with CORB or COVB specification in > the regression procedure? By residual mean square I mean, for a simple > linear regression model, > ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the > actual y value. > I am running a regression procedure in a loop in a DEFINE and need to be > able to uniquely identify the files that have the residual mean square > (each with a name like concat(RME,!i), where !i is the DEFINE loop > variable). This can be done with the CORB and COVB specifications. > Stan > > ===================== > To manage your subscription to SPSSX-L, send a message to > LISTSERV@.UGA > (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > < > /quote<quote author="Stan Gorodenski" > > > I have what is a simple question. Is there a way to save the residual > mean square is a file like one can do with CORB or COVB specification in > the regression procedure? By residual mean square I mean, for a simple > linear regression model, > ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the > actual y value. > I am running a regression procedure in a loop in a DEFINE and need to be > able to uniquely identify the files that have the residual mean square > (each with a name like concat(RME,!i), where !i is the DEFINE loop > variable). This can be done with the CORB and COVB specifications. > Stan > > ===================== > To manage your subscription to SPSSX-L, send a message to > LISTSERV@.UGA > (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD ----- Please reply to the list and not to my personal email. Those desiring my consulting or training services please feel free to email me. --- "Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis." Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?" -- Sent from: http://spssx-discussion.1045642.n5.nabble.com/ ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Please reply to the list and not to my personal email.
Those desiring my consulting or training services please feel free to email me. --- "Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis." Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?" |
Thanks, David. This is a personal project and so it does not require the
rigor that might be necessary in a working environment. I already have the syntax from previous work on this that takes the coefficients in the COVB file to compute the estimate. With these I can compute the residuals. I am surprised SPSS does not include writing out the mean square errors in any of the files like COVB, CORB, or COVRATIO. Wading into OMS and MATRIX is more than I want to spend time on. Stan On 8/13/2018 6:42 AM, David Marso wrote: > Look into OMS. An alternative is to roll your own with MATRIX. > > > Stan Gorodenski wrote > >> I have what is a simple question. Is there a way to save the residual >> mean square is a file like one can do with CORB or COVB specification in >> the regression procedure? By residual mean square I mean, for a simple >> linear regression model, >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >> actual y value. >> I am running a regression procedure in a loop in a DEFINE and need to be >> able to uniquely identify the files that have the residual mean square >> (each with a name like concat(RME,!i), where !i is the DEFINE loop >> variable). This can be done with the CORB and COVB specifications. >> Stan >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> > >> LISTSERV@.UGA >> > >> (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> < >> /quote<quote author="Stan Gorodenski" >> > >> I have what is a simple question. Is there a way to save the residual >> mean square is a file like one can do with CORB or COVB specification in >> the regression procedure? By residual mean square I mean, for a simple >> linear regression model, >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >> actual y value. >> I am running a regression procedure in a loop in a DEFINE and need to be >> able to uniquely identify the files that have the residual mean square >> (each with a name like concat(RME,!i), where !i is the DEFINE loop >> variable). This can be done with the CORB and COVB specifications. >> Stan >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> > >> LISTSERV@.UGA >> > >> (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> > > > > > ----- > Please reply to the list and not to my personal email. > Those desiring my consulting or training services please feel free to email me. > --- > "Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis." > Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?" > -- > Sent from: http://spssx-discussion.1045642.n5.nabble.com/ > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > > > ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
OMS is a powerful tool that is well worth getting to know. It provides a general solution for capturing tables or other output in any of a large number of formats including sav, text, Excel, html, and others. It works by watching for occurrences of the selected object types in the Viewer between the time it is started and when it is turned off, at which point the output is written. Here is an example that saves the ANOVA table from a regression as a text file. OMS SELECT TABLES /IF SUBTYPES='ANOVA' /DESTINATION OUTFILE="C:\TEMP\ANOVA.TXT" FORMAT=TEXT. REGRESSION /STATISTICS COEFF OUTS R ANOVA /DEPENDENT salary /METHOD=ENTER educ jobtime prevexp. OMSEND. The appropriate table subtype can be determined by right clicking in the outline on an instance or using Utilities > OMS Control Panel. On Mon, Aug 13, 2018 at 10:48 AM Stan Gorodenski <[hidden email]> wrote: Thanks, David. This is a personal project and so it does not require the |
Thanks, Jon. It looks like something worthwhile to learn.
Stan On 8/13/2018 10:17 AM, Jon Peck wrote: > OMS is a powerful tool that is well worth getting to know. It > provides a general solution for capturing tables or other output in > any of a large number of formats including sav, text, Excel, html, and > others. It works by watching for occurrences of the selected object > types in the Viewer between the time it is started and when it is > turned off, at which point the output is written. > > Here is an example that saves the ANOVA table from a regression as a > text file. > OMS SELECT TABLES /IF SUBTYPES='ANOVA' > /DESTINATION OUTFILE="C:\TEMP\ANOVA.TXT" FORMAT=TEXT. > > REGRESSION > /STATISTICS COEFF OUTS R ANOVA > /DEPENDENT salary > /METHOD=ENTER educ jobtime prevexp. > > OMSEND. > > The appropriate table subtype can be determined by right clicking in > the outline on an instance or using Utilities > OMS Control Panel. > > > > On Mon, Aug 13, 2018 at 10:48 AM Stan Gorodenski > <[hidden email] <mailto:[hidden email]>> wrote: > > Thanks, David. This is a personal project and so it does not > require the > rigor that might be necessary in a working environment. I already > have > the syntax from previous work on this that takes the coefficients > in the > COVB file to compute the estimate. With these I can compute the > residuals. I am surprised SPSS does not include writing out the mean > square errors in any of the files like COVB, CORB, or COVRATIO. > Wading > into OMS and MATRIX is more than I want to spend time on. > Stan > > On 8/13/2018 6:42 AM, David Marso wrote: > > Look into OMS. An alternative is to roll your own with MATRIX. > > > > > > Stan Gorodenski wrote > > > >> I have what is a simple question. Is there a way to save the > residual > >> mean square is a file like one can do with CORB or COVB > specification in > >> the regression procedure? By residual mean square I mean, for a > simple > >> linear regression model, > >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y > is the > >> actual y value. > >> I am running a regression procedure in a loop in a DEFINE and > need to be > >> able to uniquely identify the files that have the residual mean > square > >> (each with a name like concat(RME,!i), where !i is the DEFINE loop > >> variable). This can be done with the CORB and COVB specifications. > >> Stan > >> > >> ===================== > >> To manage your subscription to SPSSX-L, send a message to > >> > > > >> LISTSERV@.UGA > >> > > > >> (not to SPSSX-L), with no body text except the > >> command. To leave the list, send the command > >> SIGNOFF SPSSX-L > >> For a list of commands to manage subscriptions, send the command > >> INFO REFCARD > >> < > >> /quote<quote author="Stan Gorodenski" > >> > > >> I have what is a simple question. Is there a way to save the > residual > >> mean square is a file like one can do with CORB or COVB > specification in > >> the regression procedure? By residual mean square I mean, for a > simple > >> linear regression model, > >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y > is the > >> actual y value. > >> I am running a regression procedure in a loop in a DEFINE and > need to be > >> able to uniquely identify the files that have the residual mean > square > >> (each with a name like concat(RME,!i), where !i is the DEFINE loop > >> variable). This can be done with the CORB and COVB specifications. > >> Stan > >> > >> ===================== > >> To manage your subscription to SPSSX-L, send a message to > >> > > > >> LISTSERV@.UGA > >> > > > >> (not to SPSSX-L), with no body text except the > >> command. To leave the list, send the command > >> SIGNOFF SPSSX-L > >> For a list of commands to manage subscriptions, send the command > >> INFO REFCARD > >> > > > > > > > > > > ----- > > Please reply to the list and not to my personal email. > > Those desiring my consulting or training services please feel > free to email me. > > --- > > "Nolite dare sanctum canibus neque mittatis margaritas vestras > ante porcos ne forte conculcent eas pedibus suis." > > Cum es damnatorum possederunt porcos iens ut salire off > sanguinum cliff in abyssum?" > > -- > > Sent from: http://spssx-discussion.1045642.n5.nabble.com/ > > > > ===================== > > To manage your subscription to SPSSX-L, send a message to > > [hidden email] <mailto:[hidden email]> > (not to SPSSX-L), with no body text except the > > command. To leave the list, send the command > > SIGNOFF SPSSX-L > > For a list of commands to manage subscriptions, send the command > > INFO REFCARD > > > > > > > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] <mailto:[hidden email]> (not > to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > > > > -- > Jon K Peck > [hidden email] <mailto:[hidden email]> > > ===================== To manage your subscription to SPSSX-L, send a > message to [hidden email] > <mailto:[hidden email]> (not to SPSSX-L), with no body text > except the command. To leave the list, send the command SIGNOFF > SPSSX-L For a list of commands to manage subscriptions, send the > command INFO REFCARD ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
Administrator
|
This post was updated on .
In reply to this post by Stan Gorodenski
EDITED: Note that the most recent posts by Jon Peck & Stan Gorodenski were not visible to me for some reason when I posted the following.
---------------------------------- 1. The OMS approach is not very difficult. Give it a try. 2. Another option would be to save the unstandardized residuals to the working data file, then square them, and use AGGREGATE to add their SUM to the file. I think you'd have to supply the df, but it would be a simple COMPUTE command to get the MSE. HTH. Stan Gorodenski wrote > Thanks, David. This is a personal project and so it does not require the > rigor that might be necessary in a working environment. I already have > the syntax from previous work on this that takes the coefficients in the > COVB file to compute the estimate. With these I can compute the > residuals. I am surprised SPSS does not include writing out the mean > square errors in any of the files like COVB, CORB, or COVRATIO. Wading > into OMS and MATRIX is more than I want to spend time on. > Stan > > On 8/13/2018 6:42 AM, David Marso wrote: >> Look into OMS. An alternative is to roll your own with MATRIX. >> >> >> Stan Gorodenski wrote >> >>> I have what is a simple question. Is there a way to save the residual >>> mean square is a file like one can do with CORB or COVB specification in >>> the regression procedure? By residual mean square I mean, for a simple >>> linear regression model, >>> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >>> actual y value. >>> I am running a regression procedure in a loop in a DEFINE and need to be >>> able to uniquely identify the files that have the residual mean square >>> (each with a name like concat(RME,!i), where !i is the DEFINE loop >>> variable). This can be done with the CORB and COVB specifications. >>> Stan >>> >>> ===================== >>> To manage your subscription to SPSSX-L, send a message to >>> >> >>> LISTSERV@.UGA >>> >> >>> (not to SPSSX-L), with no body text except the >>> command. To leave the list, send the command >>> SIGNOFF SPSSX-L >>> For a list of commands to manage subscriptions, send the command >>> INFO REFCARD >>> < >>> /quote<quote author="Stan Gorodenski" >>> > >>> I have what is a simple question. Is there a way to save the residual >>> mean square is a file like one can do with CORB or COVB specification in >>> the regression procedure? By residual mean square I mean, for a simple >>> linear regression model, >>> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >>> actual y value. >>> I am running a regression procedure in a loop in a DEFINE and need to be >>> able to uniquely identify the files that have the residual mean square >>> (each with a name like concat(RME,!i), where !i is the DEFINE loop >>> variable). This can be done with the CORB and COVB specifications. >>> Stan >>> >>> ===================== >>> To manage your subscription to SPSSX-L, send a message to >>> >> >>> LISTSERV@.UGA >>> >> >>> (not to SPSSX-L), with no body text except the >>> command. To leave the list, send the command >>> SIGNOFF SPSSX-L >>> For a list of commands to manage subscriptions, send the command >>> INFO REFCARD >>> >> >> >> >> >> ----- >> Please reply to the list and not to my personal email. >> Those desiring my consulting or training services please feel free to >> email me. >> --- >> "Nolite dare sanctum canibus neque mittatis margaritas vestras ante >> porcos ne forte conculcent eas pedibus suis." >> Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff >> in abyssum?" >> -- >> Sent from: http://spssx-discussion.1045642.n5.nabble.com/ >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> > LISTSERV@.UGA > (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> >> >> > > ===================== > To manage your subscription to SPSSX-L, send a message to > LISTSERV@.UGA > (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD ----- -- Bruce Weaver bweaver@lakeheadu.ca http://sites.google.com/a/lakeheadu.ca/bweaver/ "When all else fails, RTFM." NOTE: My Hotmail account is not monitored regularly. To send me an e-mail, please use the address shown above. -- Sent from: http://spssx-discussion.1045642.n5.nabble.com/ ===================== To manage your subscription to SPSSX-L, send a message to LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
--
Bruce Weaver bweaver@lakeheadu.ca http://sites.google.com/a/lakeheadu.ca/bweaver/ "When all else fails, RTFM." PLEASE NOTE THE FOLLOWING: 1. My Hotmail account is not monitored regularly. To send me an e-mail, please use the address shown above. 2. The SPSSX Discussion forum on Nabble is no longer linked to the SPSSX-L listserv administered by UGA (https://listserv.uga.edu/). |
#2 assumes a constant in the equation. But also the dimensionality in #2 is wrong. While the answer is right, it shouldn't be of casewise dimension. On Mon, Aug 13, 2018 at 3:28 PM Bruce Weaver <[hidden email]> wrote: 1. The OMS approach is not very difficult. Give it a try. -- |
In reply to this post by Stan Gorodenski
If you say WHY you want RMSE, there might be an easier alternative that serves the same purpose. For instance, if your want to know which of
several variables adds most to a set of predictors, SPSS gives you that
directly by using STEP to put in the fixed ones; then you look at the statistics on the variables-not-in-the-equation.
-- Rich Ulrich From: SPSSX(r) Discussion <[hidden email]> on behalf of Stan Gorodenski <[hidden email]>
Sent: Monday, August 13, 2018 12:47:54 PM To: [hidden email] Subject: Re: Regression Question Thanks, David. This is a personal project and so it does not require the
rigor that might be necessary in a working environment. I already have the syntax from previous work on this that takes the coefficients in the COVB file to compute the estimate. With these I can compute the residuals. I am surprised SPSS does not include writing out the mean square errors in any of the files like COVB, CORB, or COVRATIO. Wading into OMS and MATRIX is more than I want to spend time on. Stan On 8/13/2018 6:42 AM, David Marso wrote: > Look into OMS. An alternative is to roll your own with MATRIX. > > > Stan Gorodenski wrote > >> I have what is a simple question. Is there a way to save the residual >> mean square is a file like one can do with CORB or COVB specification in >> the regression procedure? By residual mean square I mean, for a simple >> linear regression model, >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >> actual y value. >> I am running a regression procedure in a loop in a DEFINE and need to be >> able to uniquely identify the files that have the residual mean square >> (each with a name like concat(RME,!i), where !i is the DEFINE loop >> variable). This can be done with the CORB and COVB specifications. >> Stan >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> > >> LISTSERV@.UGA >> > >> (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> < >> /quote<quote author="Stan Gorodenski" >> > >> I have what is a simple question. Is there a way to save the residual >> mean square is a file like one can do with CORB or COVB specification in >> the regression procedure? By residual mean square I mean, for a simple >> linear regression model, >> ((y-(a+bx))**2)/(N-df), where df is degrees of freedom, and y is the >> actual y value. >> I am running a regression procedure in a loop in a DEFINE and need to be >> able to uniquely identify the files that have the residual mean square >> (each with a name like concat(RME,!i), where !i is the DEFINE loop >> variable). This can be done with the CORB and COVB specifications. >> Stan >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> > >> LISTSERV@.UGA >> > >> (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> > > > > > ----- > Please reply to the list and not to my personal email. > Those desiring my consulting or training services please feel free to email me. > --- > "Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis." > Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?" > -- > Sent from: http://spssx-discussion.1045642.n5.nabble.com/ > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > > > ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
Free forum by Nabble | Edit this page |