cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Submit your abstract to the call for content for Discovery Summit Americas by April 23. Selected abstracts will be presented at Discovery Summit, Oct. 21- 24.
Discovery is online this week, April 16 and 18. Join us for these exciting interactive sessions.
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!