Subscribe Bookmark RSS Feed

Trying to place all output into a journal

lodey101

Community Trekker

Joined:

Oct 4, 2011

Hi there,

I have the follwoing script that works to a certain extent. It compiles the data and creates the output but what I need to do is place all the graphs onto a journal:

Code so far:

Try( Close( dt, no save ) );

Try( Close( tempdt, no save ) );

Try( Close( dtNAME, no save));

Try (Close( vlb, no save ));

//Open CSV file for analysis

dt = Open(

                    "C:\Users\LAST24hrs.csv",

          );

          //Get List of unique Values

date_yas = dt<< Associative Array( :Datetrim << get values ) << get keys;

//create Temp Table with Names

tempdt = New Table( "Name_temp" );

tempdt << New Column( "Name_ID", character, nominal );

For( i = 1, i <= N Row( dt ), i++,

          variable = Column( dt, "NAME" );

          tempdt << addrows( 1 );

          Column( tempdt, "Name_ID" ) = variable;

);

dtNAME = Data Table( "Name_temp" ) << Join(

          With( Data Table( "Name_temp" ) ),

          By Matching Columns( :Name_ID = :Name_ID ),

          Drop multiples( 1, 1 ),

          Name( "Include non-matches" )(0, 0),

          Output Table( "Name_group" )

);

Try( Close( tempdt, no save ) );

//date = Associative Array( :Datetrim << get values ) << get keys;

// Make new window

New Window( "Output", vlb = V List Box() );

// Populate window iteratively

//create the graphs

For( i = 1, i <= N Row( dtNAME ), i++,

          variable = Column( dtNAME, "Name_ID" );

          //For( a = 1, a <= N Items( date_yas ), a++,

        //vlb << append(

                    dt<<Overlay Plot(

          SendToByGroup( Bygroup Default ),

          X( :real_x ),

          Y( :real_y ),

          Grouping( :Datetrim ),

          Where( :NAME == variable ),

          SendToReport(

                    Dispatch( {}, "Overlay Plot", OutlineBox, {Set Title( variable )} ),

                    Dispatch( {}, "Overlay Plot Graph", FrameBox , {Frame Size( 297, 293 ),Background Color( -16776960 )} )

          )

          ),

//( Report( test ) << Parent )[Text Box( 1 )] << Delete;  

);

vlb << append report;

The append report does not work...any help on where i could be going wrong?