Share your ideas for the JMP Scripting Unsession at Discovery Summit by September 17th. We hope to see you there!
Choose Language Hide Translation Bar
Highlighted
Ted
Ted
Level IV

X-axis format

How to divide the X-axis into equal parts (SEE picture)?
P.S. X-axis is not interactive in the "Y by X platform"

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
julian
Community Manager Community Manager

Re: X-axis format

Hi @Ted,

Mosaic plots (which is the default visual you will get in Fit Y by X when you use a categorical X and categorical Y) do not divide the x-axis evenly unless there is an equal number of observations in each of the categories represented by the x-axis. You can see the documentation for mosaic plots here. There isn't a way to disable this scaling in Fit Y by X because it's a feature of the plot itself. And, it's a good thing! Because of that scaling, you can see the marginal distribution of your X-variable, which is quite useful to see in addition to the conditional distribution of Y for each X category. 

 

If you absolutely need a plot that sizes the X-axis uniformly irrespective of the distribution of X, it won't be a mosaic plot. But, you can make such a plot in Graph > Graph Builder, by placing your Y variable in the Y Role, and your X variable not in the X-Role, but in the Group X role at the top. Then, toggle the mosaic plot at the top to make a mosaic-like plot.

 

gb.gif

 

 

I hope this helps,

@julian 

View solution in original post

2 REPLIES 2
Highlighted

Re: X-axis format

Sorry - I was mistaken that you could turn off the proportional spacing in the Contingency platform. (I never wanted to turn it off.) I must be thinking of Oneway, another platform under Fit Y by X.

Learn it once, use it forever!
Highlighted
julian
Community Manager Community Manager

Re: X-axis format

Hi @Ted,

Mosaic plots (which is the default visual you will get in Fit Y by X when you use a categorical X and categorical Y) do not divide the x-axis evenly unless there is an equal number of observations in each of the categories represented by the x-axis. You can see the documentation for mosaic plots here. There isn't a way to disable this scaling in Fit Y by X because it's a feature of the plot itself. And, it's a good thing! Because of that scaling, you can see the marginal distribution of your X-variable, which is quite useful to see in addition to the conditional distribution of Y for each X category. 

 

If you absolutely need a plot that sizes the X-axis uniformly irrespective of the distribution of X, it won't be a mosaic plot. But, you can make such a plot in Graph > Graph Builder, by placing your Y variable in the Y Role, and your X variable not in the X-Role, but in the Group X role at the top. Then, toggle the mosaic plot at the top to make a mosaic-like plot.

 

gb.gif

 

 

I hope this helps,

@julian 

View solution in original post

Article Labels

    There are no labels assigned to this post.