Turn on suggestions

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

Showing results for

- JMP User Community
- :
- Discussions
- :
- Only three quantiles reported for fitted distribution

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

Highlighted

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

Dec 15, 2014 9:23 AM
(7866 views)

Hi,

when you analyze the distribution of a sample of a continuous variable, you can customize the output to show upto ten quantiles using the "Custom Quantiles" option. But when you fit a distribution on the data, then you can only define three probabilities for the quantiles to be shown.

Is it possible to get more quantiles of the fitted distribution in any other way?

Thanks

Dave

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted

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

The user interface only provides up to three quantiles at a time. A script could be written to compute any number of quantiles and add the results in a a custom report to the Distribuiton platform. If your analysis is common, then it could incorporate launching the Distribution platform on the variable and either directly add the report for a pre-defined set of quantiles or first open a dialog with ten number entry boxes.

Learn it once, use it forever!

4 REPLIES 4

Highlighted

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

The user interface only provides up to three quantiles at a time. A script could be written to compute any number of quantiles and add the results in a a custom report to the Distribuiton platform. If your analysis is common, then it could incorporate launching the Distribution platform on the variable and either directly add the report for a pre-defined set of quantiles or first open a dialog with ten number entry boxes.

Learn it once, use it forever!

Highlighted
##

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

Re: Only three quantiles reported for fitted distribution

Hi Mark,

thanks for the tip. Unfortunately I have no experience with scripting. I have tried the following:

Open**(** "$SAMPLE_DATA/Diabetes.jmp" **)**;

Distribution (

** **** Continuous Distribution (**

Column**(** :BMI **)**,

Fit Distribution**(** Normal**(** Quantiles**(** **0.01**, **0.05**, **0.95**, **0.99** **)** **)** **)**

**)**

**)**;

but the results will only show the first three quantiles.

I hope you can elaborate a bit on the matter.

Best,

Dave

Highlighted
##

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

Re: Only three quantiles reported for fitted distribution

You need to calculate the quantiles "outside" the platform and then append them to the report. There are many ways to do this. Example:

dt = Open**(** "$SAMPLE_DATA/Diabetes.jmp" **)**;

dist = dt << **Distribution****(**

Continuous Distribution**(** Column**(** :BMI **)**, Fit Distribution**(** Normal**()** **)** **)**

**)**;

rdist = dist << **report**;

// Array of the desired percentiles

p = **[****0.99** **0.95** **0.90** **0.75** **0.5** **0.25** **0.10** **0.05** **0.01****]**;

// Get the parameters for fitted normal and calculate the quantiles

**{**mu, sigma**}** = rdist**[**Number Col Box**(** "Estimate" **)]** << **get**;

q = Normal Quantile**(** p, mu, sigma **)**;

// Add quantile table to report

rdist**[**Outline Box**(** "Parameter Estimates" **)]** << **append****(**

Table Box**(** Number Col Box**(** "Percentile", p **)**, Number Col Box**(** "Quantile", q **)** **)**

**)**;

Highlighted
##

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

Re: Only three quantiles reported for fitted distribution

Thanks ever so much MS! I see that it is a rather tought thing for a beginner to come up to. I have looked for information in

Just one final question, if you will allow me. Is it posible to do that to include other variables?. So for two variables (in this case BMI and BP), I manage to generate the distribution report and normal fitting, but the "extension" of the quantiles is only appended for the first variable. I see that "mu" and "sigma" are given the values for the first variable and the second variable is not included. I don`t seem to find the appropriate information in the scripting guide.

dt = Open**(** "$SAMPLE_DATA/Diabetes.jmp" **)**;

dist = dt << **Distribution(**

Stack**(** **1** **)**,

Column**(** :BMI **)**,

Horizontal Layout**(** **1** **)**,

Vertical**(** **0** **)**,

Outlier Box Plot**(** **0** **)**,

Normal Quantile Plot**(** **1** **)**,

Fit Distribution**(** Normal**(** Goodness of Fit**(** **1** **)** **)** **)**,

CV**(** **1** **)**,

Minimum**(** **1** **)**,

Maximum**(** **1** **)**,

Interquartile Range**(** **1** **)**

**)**,

Column**(** :BP **)**,

Horizontal Layout**(** **1** **)**,

Vertical**(** **0** **)**,

Outlier Box Plot**(** **0** **)**,

Normal Quantile Plot**(** **1** **)**,

Fit Distribution**(** Normal**(** Goodness of Fit**(** **1** **)** **)** **)**,

CV**(** **1** **)**,

Minimum**(** **1** **)**,

Maximum**(** **1** **)**,

Interquartile Range**(** **1** **)**

**)**;

rdist = dist << **report**;

p = **[****0.99** **0.95** **0.90** **0.75** **0.5** **0.25** **0.10** **0.05** **0.01]**;

**{**mu, sigma**}** = rdist**[**Number Col Box**(** "Estimate" **)]** << **get**;

q = Normal Quantile**(** p, mu, sigma **)**;

rdist**[**Outline Box**(** "Parameter Estimates" **)]** << **append(**

Table Box**(** Number Col Box**(** "Percentile", p **)**, Number Col Box**(** "Quantile", q **)** **)**

**)**;

Article Labels

There are no labels assigned to this post.