Mit einem Local Data Filter und einer geringfügigen Änderung der Rohdatentabelle können Sie auf einfache Weise das tun, was Sie möchten
names default to here(1);
// Create the sample data
dt = New Table( "Raw Data",
Add Rows( 31 ),
New Column("Age",
Set Values(
[42, 38, 43, 50, 49, 38, 49, 52, 57, 51, 40, 49, 44, 48, 54, 52, 52, 47,
43, 51, 51, 45, 54, 44, 48, 47, 40, 57, 54, 44, 45]
)
),
New Column("Weight",
Set Values(
[68.15, 81.87, 85.84, 70.87, 81.42, 89.02, 76.32, 76.32, 59.08, 77.91,
75.07, 73.37, 73.03, 91.63, 83.12, 73.71, 82.78, 79.15, 81.19, 69.63,
67.25, 66.45, 79.38, 89.47, 61.24, 77.45, 75.98, 73.37, 91.63, 81.42,
87.66]
)
),
New Column("Oxy",
Set Values(
[59.571, 60.055, 54.297, 54.625, 49.156, 49.874, 48.673, 45.441, 50.545,
46.672, 45.313, 50.388, 50.541, 46.774, 51.855, 45.79, 47.467, 47.273,
49.091, 40.836, 45.118, 44.754, 46.08, 44.609, 47.92, 44.811, 45.681,
39.407, 39.203, 39.442, 37.388]
)
),
New Column("Runtime",
Set Values(
[8.17, 8.63, 8.65, 8.92, 8.95, 9.22, 9.4, 9.63, 9.93, 10, 10.07, 10.08,
10.13, 10.25, 10.33, 10.47, 10.5, 10.6, 10.85, 10.95, 11.08, 11.12,
11.17, 11.37, 11.5, 11.63, 11.95, 12.63, 12.88, 13.08, 14.03]
)
),
New Column("RunPulse",
Set Values(
[166, 170, 156, 146, 180, 178, 186, 164, 148, 162, 185, 168, 168, 162,
166, 186, 170, 162, 162, 168, 172, 176, 156, 178, 170, 176, 176, 174,
168, 174, 186]
)
),
New Column("RstPulse",
Set Values(
[40, 48, 45, 48, 44, 55, 56, 48, 49, 48, 62, 67, 45, 48, 50, 59, 53, 47,
64, 57, 48, 51, 62, 62, 52, 58, 70, 58, 44, 63, 56]
),
Set Display Width( 62 )
),
New Column("MaxPulse",
Set Values(
[172, 186, 168, 155, 185, 180, 188, 166, 155, 168, 185, 168, 168, 164,
170, 188, 172, 164, 170, 172, 172, 176, 165, 182, 176, 176, 180, 176,
172, 176, 192]
)
)
);
// Summarize the data
dtSum = dt << Summary(
Mean( :Age ),
Mean( :Weight ),
Mean( :Oxy ),
Mean( :Runtime ),
Mean( :RunPulse ),
Mean( :RstPulse ),
Mean( :MaxPulse ),
Freq( "None" ),
Weight( "None" ),
statistics column name format( "column" ),
Link to original data table( 0 ),
Output Table Name( "Mean" )
);
// Clean up table
dtSum << delete columns("N Rows");
// Concatenate the data tables
dt = dt << Concatenate(
dtSum,
Create source column,
Append to First Table
);
// Delete the summary table
close(dtSum, nosave);
// Create the graph
dt << Graph Builder(
Size( 495, 448 ),
Show Control Panel( 0 ),
Variables(
X( :Weight ),
X( :Oxy, Position( 1 ) ),
X( :Runtime, Position( 1 ) ),
X( :RunPulse, Position( 1 ) ),
X( :RstPulse, Position( 1 ) ),
X( :MaxPulse, Position( 1 ) )
),
Elements(
Parallel( X( 1 ), X( 2 ), X( 3 ), X( 4 ), X( 5 ), X( 6 ), Legend( 6 ) )
),
Local Data Filter(
Add Filter( columns( :Source Table ), Where( :Source Table == "Raw Data" ) )
)
);