topic Re: Parameterization choice and model comparison in logistic regression. in Discussions
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262767#M51380
<P>When I look at your models, it looks like year and change are highly significant individually. When you put the cross (interaction) effect, none of the parameter estimates look significant, but the overall model is. But I don't understand the sense of putting an interaction between year and change in your model - the change variable just reports whether the year is before or after some intervention time, so it doesn't make much sense to me to put the interaction. I suppose what you are asking for is whether the year has a different effect on the target in the Pre and post periods. I think the more direct way to examine this is to Fit Y (target) by X (year) and put the change (Pre and Post) in the By box. When you do this you will see that year is far from significant in the Pre period but quite significant in the Post period. I think that answers your question. If you need a test of whether the slope (nonlinear here) is significantly different in the two periods, I'm not exactly sure what the appropriate test is - but I think it is evident that the effect of year differs significantly in the two periods.</P>Thu, 30 Apr 2020 11:41:39 GMTdale_lehman2020-04-30T11:41:39ZParameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262471#M51354
<P>Dear members of the forum,</P>
<P>I am analyzing this data set with a dependent binary variable (Target), using a logistic regression for hypothesis testing rather than prediction on this real-life data.</P>
<P>I would like to utilize the model parameterization in order to assess whether the trend over time (years) is stronger (constant) or perhaps the momentary change is more meaningful as a breaking point.</P>
<P>When used separately, models are similar with perhaps better fit using the continuous Year variable. On the other hand, the technical change is the reason for modeling in the first place so can’t be ignored.</P>
<P>Once put together with the interaction all parameters are insignificant (perhaps multicollinearity, small sample size, too much variance or all together) which gives the false impression of no change in propensity over time.</P>
<P>Please do let me know if you have any suggestions in terms of model specification or comparisons for reaching a clearer conclusion.</P>
<P>Attached is the data table with a script for the alternative models.</P>
<P> </P>Wed, 29 Apr 2020 22:31:08 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262471#M51354ron_horne2020-04-29T22:31:08ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262767#M51380
<P>When I look at your models, it looks like year and change are highly significant individually. When you put the cross (interaction) effect, none of the parameter estimates look significant, but the overall model is. But I don't understand the sense of putting an interaction between year and change in your model - the change variable just reports whether the year is before or after some intervention time, so it doesn't make much sense to me to put the interaction. I suppose what you are asking for is whether the year has a different effect on the target in the Pre and post periods. I think the more direct way to examine this is to Fit Y (target) by X (year) and put the change (Pre and Post) in the By box. When you do this you will see that year is far from significant in the Pre period but quite significant in the Post period. I think that answers your question. If you need a test of whether the slope (nonlinear here) is significantly different in the two periods, I'm not exactly sure what the appropriate test is - but I think it is evident that the effect of year differs significantly in the two periods.</P>Thu, 30 Apr 2020 11:41:39 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262767#M51380dale_lehman2020-04-30T11:41:39ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262793#M51383
<P>Thank you <LI-USER uid="1701"></LI-USER> for the advice.</P>
<P> </P>
<P>That is the thing, Ideally, I would be able to assess whether there is an overall trend over time as well as a braking point at 2005. Therefore, the use of both the year and the dummy variable were supposed to allow exactly that. This way I would have an estimate for the slope in each period and well as a dummy for continuity between them.</P>
<P>I can estimate the slope for the post period directly by reversing the value ordering of “Change” as in the attached output. I get the same insignificance. Splitting the data, I get an overall significant model with an insignificant slope. Which to me shoes this is trend not very robust – am I right?</P>
<P>From all the alternative models, could you suggest a logical path do determine whether there is a trend in each period and is there a braking point (change in trend).</P>Thu, 30 Apr 2020 12:27:16 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262793#M51383ron_horne2020-04-30T12:27:16ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262804#M51385
<P>I think you are too focused on finding a low p-value. It looks like your data shows what you are looking for - the year has no clear effect prior to 2005, but a significant effect after. This is readily seen by running two separate logistic regressions - target as a function of year, in the pre- and post- periods. What more do you need?</P>Thu, 30 Apr 2020 12:37:12 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262804#M51385dale_lehman2020-04-30T12:37:12ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262809#M51386
<P>I hope that this reply follows the first three!</P>
<P> </P>
<P>The problem sounds like 'change point analysis' and the approach is very similar to those used in this technique. You have a sliding definition of period 1 and period 2 and use a metric like minimum AICc to decide the point where the behavior (e.g., mean, slope, et cetera) changed. That is, as the change point varies, you re-fit the model and capture the metric, then plot the metric versus the change point.</P>Thu, 30 Apr 2020 12:47:29 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262809#M51386markbailey2020-04-30T12:47:29ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262927#M51409
<P><LI-USER uid="1701"></LI-USER> </P>
<P>Thank you for your answer, I was hoping there is another way of introducing the Year and Change variables in a model since this is not the classical ANCOVA where two independent variables present completely different dimensions (i.e. age and gender).</P>
<P> </P>
<P><LI-USER uid="5358"></LI-USER> </P>
<P>Thanks for the lead, but I am not sure at all my data is appropriate. Could you tell me how to go about in terms of platform and variable roles?</P>
<P>I was not sure my data is appropriate. This is real data from political science (numbers are real, variable names changed), therefore, observations are not exactly sequential, they do have an exact date but it is not meaningful within the year. I am also not sure I should be looking for the best fit split in the data. The technical change may have taken time to “kick in” but there is no interest in estimating that lag (which would be very important in process monitoring). I just need a way of estimating the probability of target across the time periods comparing the two periods (pre and post) while controlling for the other variables.</P>
<P>I was hoping I can crudely estimate the trend using the Year variable and test whether there is a change in it or perhaps gain insight that it is just a drop between pre and post.</P>
<P> </P>
<P>This discussion is helping me go through the whole thinking process of the modeling and the context. Thanks a lot!</P>Thu, 30 Apr 2020 19:36:11 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/262927#M51409ron_horne2020-04-30T19:36:11ZRe: Parameterization choice and model comparison in logistic regression.
https://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/263168#M51445
<P>You use the Logistic Regression platform. Use <STRONG>date</STRONG>, not year. Create a binary variable for <STRONG>period</STRONG> (<EM>before</EM>, <EM>after</EM>). Fit a model where the linear predictor is <STRONG>date</STRONG>, <STRONG>period</STRONG>, and <STRONG>period*date</STRONG>. Change the period values based on date. (Imagine that the observations are sorted by date in ascending order. Set all rows to <STRONG>period</STRONG> = <EM>after</EM>.for the first fit. Now advance period to the second date, so <STRONG>period</STRONG> = <EM>before</EM> for row 1 and the remainder remain set as <STRONG>period</STRONG> = <EM>after</EM>. Progress until <STRONG>period</STRONG> = <EM>before</EM> for all rows.. Collect the AICc criterion for each fit. Plot the criterion versus date to see where the change occurred. Evaluate that model as you normally would.</P>
<P> </P>
<P>Note that you might want to avoid the boundary issue with all rows having the same level for period.</P>
<P> </P>
<P>I am not sure if this approach will help. Just an idea.</P>Fri, 01 May 2020 14:57:06 GMThttps://community.jmp.com/t5/Discussions/Parameterization-choice-and-model-comparison-in-logistic/m-p/263168#M51445markbailey2020-05-01T14:57:06Z