BookmarkSubscribe
Choose Language Hide Translation Bar
KinKame
Community Trekker

Add Pin Annotation

Hello JMP community,

having to solve an issue whit adding Add Pin Annotation.

how to add a pin annotation to a script for graph builder?

X is working week. The pin should only be visible on latest week data

Y is 4 parameters but I only want the PIN annotation for 1 of them

I found following script in the help section bit it doesn't help me

Names Default To Here( 1 );

//This message applies to all display box objects

Open( "$SAMPLE_DATA/Big Class.jmp" );

Bivariate(

  Y( :weight ),

  X( :height ),

  SendToReport(

  Dispatch(

  {},

  "Bivar Plot",

  FrameBox,

  Add Pin Annotation(

  Seg( Marker Seg( 1 ) ),

  Index( 17 ),

  UniqueID( 251970065 ),

  FoundPt( {276, 112} ),

  Origin( {64.9765625, 142} ),

  Offset( {-174, -40} ),

  Tag Line,

  Font( "Helvetica", 11, "Plain" )

  )

  )

  )

);

best regards

Lionel

0 Kudos
1 REPLY 1
Vball247
Community Trekker

Re: Add Pin Annotation

I'm trying to do something similar. First of all, you can see the performance of the Add Pin Annotation by doing it manually, and then look at the script. The Scripting Index is missing UniqueID() argument. Apparently you can put in any number, like UniqueID(1)? My saved script from the graph has UniqueID like "859424637" but any number may work. I will see if they can fix that in JMP15EA. I am using JMP14.2.

Also another note: The Index and Index Row start counting from 0, not 1. So in the Scripting Index example, Index(17) is Leslie, which is Row 18, not Row 17. If you pin annotation on Row 1, Katie, it will show Index( 0 ).

 

Names Default To Here( 1 );
//This message applies to all display box objects
Open( "$SAMPLE_DATA/Big Class.jmp" );
Bivariate(
	Y( :weight ),
	X( :height ),
	SendToReport(
		Dispatch(
			{},
			"Bivar Plot",
			FrameBox,
			Add Pin Annotation(
				Seg( Marker Seg( 1 ) ),
				Index( 17 ),
				Index Row( 17 ),
				UniqueId( 1 ), // this is missing in Scripting Guide
				Origin( {64.9765625, 142} ),
				Offset( {-174, -40} ),
				Tag Line,
				Font( "Helvetica", 11, "Plain" )
			)
		)
	)
);