cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to create experiments to support product design and ID useful product features. Register for June 12 webinar, 2pm US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar

Multiple custom bivariate charts

Hi,

I am writing a script to plot multiple custom bivariate charts (for each group).  I have created the column dialog to choose the respective columns. However, it seems there is any error stating "Bad Argument( {Xaxis, Role requires at least 1 columns., Yaxis,  Role requires at least 1 columns.}". Pls advise.

ColDlg = Column Dialog(

  Yaxis = ColList( "Y-axis", MaxCol( 1 ), Datatype( Numeric ) ),

  Xaxis = ColList( "X-axis", MaxCol( 1 ), Datatype( Numeric ) ),

  Bycol = ColList( "Group by", MaxCol( 1 ), Datatype( Character ) ),

  );

  If( ColDlg["button"] == 1,

  Yaxis = Column( Current Data Table(), Coldlg["Yaxis"] );

  Xaxis = Column( Current Data Table(), Coldlg["Xaxis"] );

  Bycol = Column( Current Data Table(), Coldlg["Bycol"] );

  summarize(Uni_Bycol = by(Bycol));

  show(Uni_Bycol);

  Bivariate(

       SendToByGroup( {Bycol == Uni_Bycol[1]} ),

       Y( Yaxis ),

       X( Xaxis ),

       By( Bycol ),

       For (j = 1, j < N Items(Uni_Bycol), j++,

       SendToByGroup(

       {Bycol == Uni_Bycol},

       SendToReport(

  Dispatch(

{},

  {"Chart Ouputt by ("|| By || ")"},

  "Bivar Plot",

  FrameBox, {Frame Size( 436, 397 ),

  Add Graphics Script(

  2,

  Description( "Boundary" ),

  Line(

  {0.2084, 0.47202},

  {0.2045, 0.46438},

  {0.1936, 0.47665},

  {0.1985, 0.48484},

  {0.2084, 0.47202}

  );

  Line(

  {0.2084, 0.47202},

  {0.2173, 0.46061},

  {0.2139, 0.45368},

  {0.2045, 0.46438},

  {0.2084, 0.47202}

  );

),

  Grid Line Order( 1 ), Reference Line Order( 3 ),

  Row Legend(

  Bycol,

  Color( 1 ),

  Color Theme( "JMP Light" ),

                                                )  },

                                     ) ) );

                           );

  ););

1 ACCEPTED SOLUTION

Accepted Solutions
ms
Super User (Alumni) ms
Super User (Alumni)

Re: Multiple custom bivariate charts

Y() and X() need evaluated arguments.Try this:

Bivariate(...,

Y( eval(Yaxis) ),

X( eval(Xaxis) ),

...);

View solution in original post

2 REPLIES 2
ms
Super User (Alumni) ms
Super User (Alumni)

Re: Multiple custom bivariate charts

Y() and X() need evaluated arguments.Try this:

Bivariate(...,

Y( eval(Yaxis) ),

X( eval(Xaxis) ),

...);

Re: Multiple custom bivariate charts

Thanks MS!

Recommended Articles