BookmarkSubscribeRSS Feed
Choose Language Hide Translation Bar
Hegedus

Community Trekker

Joined:

Jun 23, 2011

Log showing error, but manual execution does not flag error

Hi,

 

I have a simple script to do six bivariates and arrange them in rows.  The graphs appear to be correct, but the log is showing an error.  When I do the manual fit via the dialog box the plots get generated (without the arrange in rows), but without any error being flagged.  I am writing this script to distribute so I would like to resolve this error.  Where should I start looking?

 

Thanks in advance

Andy

 

 

Name Unresolved: By in access or evaluation of 'By' , By( :device_ID ) /*###*/Exception in platform launch in access or evaluation of 'Fit Group' , Fit Group(/*###*/Bivariate( Y( :Charge_Transfer_%0 ), X( :cycle_num ) ),

Bivariate( Y( :TvB_%0 ), X( :cycle_num ) ),

Bivariate( Y( :TvD_%0 ), X( :cycle_num ) ),

Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),

Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),

Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),

<<{Arrange in Rows( 6 )},

By( :device_ID )

)

 

In the following script, error marked by /*###*/

Fit Group(

Bivariate( Y( :Charge_Transfer_%0 ), X( :cycle_num ) ),

Bivariate( Y( :TvB_%0 ), X( :cycle_num ) ),

Bivariate( Y( :TvD_%0 ), X( :cycle_num ) ),

Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),

Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),

Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),

<<{Arrange in Rows( 6 )},

By( :device_ID ) /*###*/

)

 

dt<<currentdatatable();
dt<<clear row states;


New Window( "Fitness - Bivariate",
	V List Box(
		Fit Group(
			Bivariate( Y( :name("Charge_Transfer_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :name("TvB_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :name("TvD_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),
			Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),
			Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),
			<<{Arrange in Rows( 6 )},
			By( :name("device_ID") )
		),
		
	)
);
1 ACCEPTED SOLUTION

Accepted Solutions
Craige_Hales

Staff

Joined:

Mar 21, 2013

Solution

Re: Log showing error, but manual execution does not flag error

Appears to be a bug in JMP 12, fixed in 13. It looks like JMP's FitGroup attempts to evaluate the by statement, in addition to actually using it to make by groups. You can work around the problem like this:

dt=open("C:\Program Files\SAS\JMPPRO\12\Samples\Data/big class.jmp");
by=0; // work around JMP 12 issue
New Window( "Big Class - Bivariate",
  V List Box(
    dt<<Fit Group(
      Bivariate( Y( :height ), X( :age ) ),
      Bivariate( Y( :weight ), X( :age ) ),
      <<{Arrange in Rows( 2 )},
      By( :name( "sex" ) )
    )
  )
);

Now JMP can evaluate the variable "by" (and ignore the zero result) without producing messages in the log. 

Edit: make it clear this problem is in FitGroup. 

Craige
12 REPLIES 12
Hegedus

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

Any help folks?

 

If I run the script the graphs get made but it is still throwing errors?

 

mikedriscoll

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

I ran a  modified version of your script, modified to match my data, and I couldn't get it to throw that error even if I deleted the column. It seems to be flagging as if it can't find the column. The fact that it is working almost seems like a JMP version issue, some cosmetic bug that was cleaned up in a later verison. What JMP version are you using?

Craige_Hales

Staff

Joined:

Mar 21, 2013

Re: Log showing error, but manual execution does not flag error

Try this

dt=open("$sample_data/big class.jmp");
New Window( "Big Class - Bivariate",
  V List Box(
    dt<<Fit Group(
      Bivariate( Y( :height ), X( :age ) ),
      Bivariate( Y( :weight ), X( :age ) ),
      <<{Arrange in Rows( 2 )},
      By( :name( "sex" ) )
    )
  )
);

which is probably only different in sending the fit group message to an explicit dt.

Craige
Hegedus

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

I am having real trouble with this.

 

I need to embed this in a longer script.  I think it is now have a related but larger issue.  The script makes serveral data tables and it is now trying to execute this the wrong data table even if a speficially set the the data table. Notice that the Fitness- Bivariate fit is being attached to the ....SPU.Data table even though  I speciffically set the other data table.  If I bring the desired data table to the for and highlight the script for the new window and execute.  It will give the correct plots but STILL throw the errors.  If executed in the script it doesn't even do that but rather gives me a "Not Found in access or evaluation of BiVariate, Bad Arguement.

 

I am using JMP 12.2.0 on both Mac and Windows.

 

HELP!

 

Wrong Data Table.png

 

datatable(OpticalData);
	
New Window( "Fitness - Bivariate",
	V List Box(
		Fit Group(
			Bivariate( Y( :name("Charge_Transfer_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :name("TvB_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :name("TvD_%0" )), X( :cycle_num ) ),
			Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),
			Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),
			Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),
			<<{Arrange in Rows( 6 )},
			By( :name("device_id") )
		),
		
	)
);

OpticalData<<select where(:outlier !="---");
OpticalData<<exclude;
OpticalData<< markers("x");
OpticalData<<clear select;
txnelson

Super User

Joined:

Jun 22, 2012

Re: Log showing error, but manual execution does not flag error

 

This might provide you with the solution.  Force the Bivariates to operate on the correct table

New Window( "Fitness - Bivariate",
	V List Box(
		Fit Group(
			OpticalData << Bivariate( Y( :name( "Charge_Transfer_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :name( "TvB_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :name( "TvD_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),
			<<{Arrange in Rows( 6 )},
			By( :name( "device_id" ) )
		), 
		
	)
);

OpticalData << select where( :outlier != "---" );
OpticalData << exclude;
OpticalData << markers( "x" );
OpticalData << clear select;
Jim
mikedriscoll

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

Along the lines of what I think JIm is trying to say, datatable() doesn't make that table the current one, at least I don't think it does. I think you want current data table(table name)

Highlighted
Hegedus

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

Hi

 

Made 2 changes:

 

1 current data table (opticaldata)

 

2. forced Bivariate to optical data

 

As suggested.

 

Currently it makes the plots so that is progress.  But it is not respecting the by device_id.  It makes plots with the fir groups and has the correct ids attached, but the plots show all the data not the subset that should be defined by device_id.  Additionally the log is showing errors with name unresolved device_id.

 

If I create a table script and execute that way it plots correctly, but the log is still complaining about device_id.

 

Andy


@mikedriscoll wrote:

Along the lines of what I think JIm is trying to say, datatable() doesn't make that table the current one, at least I don't think it does. I think you want current data table(table name)


 

	OpticalData << Bivariate( Y( :name( "Charge_Transfer_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :name( "TvB_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :name( "TvD_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "a*_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "b*_%0" ) ), X( :cycle_num ) ),
			OpticalData << Bivariate( Y( :Name( "L*_%0" ) ), X( :cycle_num ) ),

 as suggested.

 

mikedriscoll

Community Trekker

Joined:

Jun 23, 2011

Re: Log showing error, but manual execution does not flag error

Are you absolutely certain you've got the name of the 'by' column exactly correct? It worked fine for me with my modified dataset, with both the by(name("colname")) syntax or just by(:colname). 

 

You can try putting something like this just before the bivariate code and seeing what it displays in the log.

show(as column(:device_id)[1])

It should display the value of the first row for that column. If not, figure out why and that will probably be your answer.

You could also try show(as column(OpticalData, :device_id)[1])

 

Sorry, I would have suggested this before... I thought your plots were correct.

cwillden

Super User

Joined:

May 1, 2017

Re: Log showing error, but manual execution does not flag error

It would probably be a lot easier to resolve this if you post a sanitized version of your data set we can test use for troubleshooting.  If you're worried about IP, just replace the values in your response column with random numbers or something.

-- Cameron Willden