嗨,
從我創建的主數據集 N個堆疊數據表基於 N種不同的參數類型並存儲它們 stkdata 。
對於每個堆疊數據表,我想創建一個不同的數據表新欄目() 公式將根據字段分隔的獨特長度和/或性質進行調整。然後,我將繪製每個堆疊數據集的圖形並引用新列中的數據。目前,圖表已設置為參考:數據和:標籤。
- 一世能夠獲得相同的公式,以便在數據表中應用得很好並繪製圖形。
- 一世不能非常清楚如何正確構建if else場景或縮小最合適的工具(Regex,Pat Match或其他)。
部分代碼:
If( N Items( found_list ) > 0,
//dt << group columns( one_group, found_list );
stkdata = dt << Stack(
columns( As List( found_list ) ),
Keep( :reference_param_one, :reference_param_two),
Output Table( "Stacked " || one_group ),
); // close stacking of columns
colreference = Column( "Label" );
If(
stkdata = Current Data Table();
Pat Match( colreference, "param_group_one" ),
stkdata << New Column( "Limit_one",
"Character",
Formula( Num( Word( 2, Word( 27, :Label, ":" ), "=" ) ) )
);
Pat Match( colreference, "param_group_two" ),
stkdata << New Column( "Limit_two",
"Character",
Formula( Num( Word( 2, Word( 75, :Label, ":" ), "=" ) ) )
);
Pat Match( colreference, "param_group_three" ),
stkdata << New Column( "Limit_three",
"Character",
Formula( Num( Word( 2, Word( 29, :Label, ":" ), "=" ) ) )
);
stkdata << Oneway( Y( :Data ), X( :Label ) )
); // close If N Items (found_list) > 0