JSL - Adding a Table to a JournalAnother JSL question, I'm trying to put a table in Journal using JSL. Here is what I am trying to do:
current_data_table << New Data View;
// Creating the Journal
nw = New Window("Journal Right Here", <<Journal,
ob = Outline Box("Section 1",
Text Box("Some description that we need here.", << Markup),
Current Journal()[TableBox(current_data_table)]
)
);Everything seems to be working but the TableBox code... I am sure it is something easy but it is stumping me.
Thank you in advance.
Re: JSL - Adding a Table to a JournalThe data table, when moved into a journal, is convered into a TableBox(). The only way that I know of to change the text size in a table box, is in the JMP Preferences. However, that will change the text size for all areas within JMP, not just the table box.
Re: JSL - Adding a Table to a JournalIs it possible to change font size for the table?
Here are my attempts but I can't seem to be able to have it actually make a change.
Names Default to Here(1);
dt = Open("$sample_data/Big Class.jmp");
nw = New Window("Tables", <<JOURNAL></JOURNAL>Re: JSL - Adding a Table to a JournalThank youRe: JSL - Adding a Table to a JournalThank youRe: JSL - Adding a Table to a JournalActually, there is the matrix display box, too.
Names Default To Here( 1 );
myMatrix = [1 2 3, 4 5 6, 7 8 9];
nw = New Window( "test", vlb = V List Box() );
vlb << Append( Matrix Box( myMatrix ) );
Re: JSL - Adding a Table to a JournalThis might work for you
names default to here(1);
myMatrix = [1 2 3, 4 5 6, 7 8 9];
nw=new window("test", vlb=vlistbox());
vlb<<APPEND></APPEND>Re: JSL - Adding a Table to a JournalYes, A 2D matrix of numbers. I was thinking if it can be converted as a table, can it be directly append to a display box?
ThanksRe: JSL - Adding a Table to a JournalAppend a matrix???
A mathematical matrix....... a = [1,2,3 4,5,6] ?
A matrix of text boxes?
Re: JSL - Adding a Table to a JournalIs it possible to append matrix to a display box without any for loop etc?Re: JSL - Adding a Table to a JournalThanks for those last 4 lines.
Re: JSL - Adding a Table to a JournalAwesome! Thank you so much for taking the time to reply, completely works.
Brad
Re: JSL - Adding a Table to a JournalThe reason it displays empty cells, is because it is a view into an existing data table. Here is another script that just adds a visual copy. The script has to be a little tricky in it's method to place the data table view under the outline box.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/big class.jmp" );
nw = New Window( "sample journal",
<<JOURNAL></JOURNAL>
Re: JSL - Adding a Table to a JournalHi Jim,
Thank you for your response. It works great. Quick question through, when I go to the Journal is shows the table with rows and columns that are completely empty (like an Excel spreadhseet) versus just the rows and column with headers. Any solutions?
Thank you in advance,
Brad
Re: JSL - Adding a Table to a JournalHere is a very simple script that does what you want:
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/big class.jmp" );
nw = New Window( "sample journal",
<<JOURNAL></JOURNAL>