Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Discussions
- :
- Re: Weights and frequencies in logistic regression

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Jul 6, 2016 11:05 AM
(6955 views)

I came across this situation where the logistic regression outcome is identical when using weights or frequencies. I find it surprising since this would not be the case for linear regression at all. Weights and frequencies have different meaning as in this link: http://blogs.sas.com/content/iml/2013/09/13/frequencies-vs-weights-in-regression.html

Does anyone know the reason for the identical outcome? Shouldn’t some parts of the estimation be different by definition?

Open**(** "$SAMPLE_DATA/Big Class.jmp" **)**;

New Window**(**"weighs and Freq",

H List Box**(**

Fit Model**(**

Freq**(** :age **)**,

Y**(** :sex **)**,

Effects**(** :weight **)**,

Personality**(** Nominal Logistic **)**,

Run**(** Likelihood Ratio Tests**(** **1** **)**, Wald Tests**(** **1** **)**, Odds Ratios**(** **1** **)**, Confidence Intervals**(** **1** **)** **)**

**)**,

Fit Model**(**

Weight**(** :age **)**,

Y**(** :sex **)**,

Effects**(** :weight **)**,

Personality**(** Nominal Logistic **)**,

Run**(** Likelihood Ratio Tests**(** **1** **)**, Wald Tests**(** **1** **)**, Odds Ratios**(** **1** **)**, Confidence Intervals**(** **1** **)** **)**

**)**

**)**

**)**;

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted
Solution

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

In platforms that are not using least squares or a normal distribution model, weights are treated in an identical fashion to frequencies. (We could probably make that more clear in the first documentation link you listed.)

In the case of logistic regression, the weight variable is treated the same way as if it were specified as a frequency. If a frequency column and a weight column are both specified, the analysis proceeds as if there are frequencies replaced by the frequency column multiplied by the weight column.

Hope that helps,

Michael

Michael Crotty

Sr Statistical Writer

JMP Development

Sr Statistical Writer

JMP Development

7 REPLIES 7

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

this is what the documentation says about it:

but i still wouldn't expect to get the exact same results replacing between weights and frequencies.

would be thankful for any help on this.

Highlighted
Solution

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

In platforms that are not using least squares or a normal distribution model, weights are treated in an identical fashion to frequencies. (We could probably make that more clear in the first documentation link you listed.)

In the case of logistic regression, the weight variable is treated the same way as if it were specified as a frequency. If a frequency column and a weight column are both specified, the analysis proceeds as if there are frequencies replaced by the frequency column multiplied by the weight column.

Hope that helps,

Michael

Michael Crotty

Sr Statistical Writer

JMP Development

Sr Statistical Writer

JMP Development

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

thank you michael@jmp,

with your permission a few more clarifications please:

- "...weights are treated in an identical fashion to frequencies." - is this documented anywhere? or indicated anywhere in the output?
- "... If a frequency column and a weight column are both specified, the analysis proceeds as if there are frequencies replaced by the frequency column multiplied by the weight column. " - i am not sure what this means can you please give a reference to the equivalent in SAS documentation?
- so all in all there is no way to do a weighted sample logistic regression in JMP?

best,

ron

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

Hi ron_horne,

I hope these responses will help clarify your questions:

1. As I said in my original response, we could do a better job of documenting this. It's really only implied by the description of Weights in the Launch Fit Model section, but I'll make a note to make the description more explicit in future versions.

2. I'm not sure of an equivalent in SAS documentation, but the idea is that if you specify both a frequency and a weight column, it should be equivalent to creating a new column that multiplies the frequency and weight columns together and then uses that new column as a frequency column in the analysis.

3. I'm not sure what type of weighted sample logistic regression you're trying to do. Can you provide an example of what you would expect to see for such an analysis?

Best,

Michael

Michael Crotty

Sr Statistical Writer

JMP Development

Sr Statistical Writer

JMP Development

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

Thank you for the extra clarification.

if i understand it correctly, in the SAS documentation of the logistic regression there is a difference between Weights:

and Frequencies:

is there a way in JMP of reproducing a regression estimate with the weights statement as in SAS?

ron.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

Ron,

I tried running the Big Class example in PROC LOGISTIC using :age as a weight variable, and it seemed like it matched the output from JMP using :age as a weight or a freq variable.

proc logistic data=big_class;

weight age;

model sex = weight;

run;

Regards,

Michael

Michael Crotty

Sr Statistical Writer

JMP Development

Sr Statistical Writer

JMP Development

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Weights and frequencies in logistic regression

thanks michael@jmp,

this is not what one would expect from the different description in the SAS documentation.

would you happen to know the reason why logistic regression behaves differently than the linear on this?

ron