Extract, verify and republish

Isolate a band of the S21 measurement, check every row in the table, and use the new Dataset as the source for a second plot. Reopen the Session afterward to check both objects.

Prepare the NPL measurement

Download npl_s21_misurato.csv (ZIP), a numeric extract from the NPL 0601 VNA measurement. It contains 201 frequencies from 2.5 to 52.5 GHz in 250 MHz steps. insertion_loss_dB is calculated as −20 log10(|S21|), with |S21| = hypot(Re(S21), Im(S21)). Loss increases as magnitude decreases. source_index counts from zero. NPL source on Zenodo, licensed CC BY 4.0.

Import the CSV in Acquisition with ID npl_s21_misurato. Assign Hz to frequency_Hz, dB to insertion_loss_dB, and 1 units to the other two columns. In Analysis → Scientific Dataset Plot, select the Dataset and enable Scientific dataset 2D. With Series, create s21 on Axis → left and bind frequency to X and loss to Y. Run the analysis and select the plot in Plots.

The S21 measurement plot shows frequency in GHz and loss in dB.
The S21 measurement plot shows frequency in GHz and loss in dB.

Select and check the band

  1. Use Data / Variants → Select area. Drag a range from around 9.6 GHz to around 20.1 GHz. In the example, the GUI summary showed 9.58953073–20.1049233 GHz.
  2. In Select data…, choose the s21 series, Graphical area, and Keep selected. Set New Dataset ID to npl_s21_banda.
  3. Press Save Selection to save the selection. Press Create Dataset to create the table. When finished, the dialog reports 42 rows from one member.
  4. Open npl_s21_banda from the Dataset browser and select Canonical table. v0001 retains Hz and v0002 retains dB. The table begins at 9,750,000,000 Hz and ends at 20,000,000,000 Hz.
The npl_s21_banda Dataset contains 42 rows, with headers in Hz and dB.
The npl_s21_banda Dataset contains 42 rows, with headers in Hz and dB.

The source ordinals are 29–70 inclusive. A row-by-row check gives exactly the original measured values for those ordinals. The losses at the two endpoints are about 3.882784 dB and 3.880592 dB. These values are at the band edges. Use the whole extracted table to find the minimum and maximum.

Republish and reopen

  1. Return to Analysis. Enable Scientific dataset 2D – rectangle selection and open its Series.
  2. Create a series with Dataset npl_s21_banda, X v0001, and Y v0002 on the left axis. Enter a recognizable label, such as “NPL S21, extracted band.” Register the series and run the analysis again.
  3. In Plots, open the second plot. The display can convert Hz to GHz. The table retains Hz.
  4. Press Save Config and close the application. Restart GX-TXT, use Open Session, and reopen the Dataset in Canonical table and the plot in Plots.
The second plot reopened from the Session uses the extracted Dataset and displays its X axis in GHz.
The second plot reopened from the Session uses the extracted Dataset and displays its X axis in GHz.

Reuse a Selection with Dataset Extract

In the rectangle exercise, save the selection with Save Selection. In Configuration → Modules → Analysis & Services, select Dataset Extract and press Enable module. In Analysis, find its tab and set the source Dataset as primary.

Rows → all
Uses every row of Primary. The example contains 31 rows.
Rows → selected
Uses the rows from Dataset selection (Selected/Unselected rows only). In the test Session, the member-based Selection contains six rows from the rectangle.
Rows → unselected
Uses the complement of the selection. The sensor example returns 25 rows. Check which filters and members are included in the Selection.
Variables → all
Keeps all available source variables.
Variables → trace
Projects the result onto the X and Y columns of the trace. Set Trace X variable (Trace mode only) and Trace Y variable (Trace mode only) when required. A member-based Selection also carries its own source bindings.
Output Dataset ID
Choose a new identifier for each run. Use Run / recalculate now and the standard Run workflow.
Dataset Extract uses Rows selected, Variables trace and the rectangle’s member Selection.
Dataset Extract uses Rows selected, Variables trace and the rectangle’s member Selection.

Open rettangolo_selected_trace in the Dataset browser. v0001 retains time in seconds, and v0003 retains measured temperature in °C. Check ordinals 6–11. In Analysis, select these two columns to publish a new series in Scientific dataset 2D. Use the table and derived plot to check that the values match the original samples.

To reuse the range on filtered signal, press Save Selection in Select graph data while channel 1 is the only member. With Dataset Extract → Variables → all, selected returned 201 rows and unselected returned 4,466. Both tables retain the value 1 in v0004. The complement is calculated against the samples that already satisfy the member filter.

Reuse a range-based Selection

To reuse the legacy Selection saved automatically by Select area on a simple XY plot, set Primary to exactly the Dataset that owns the Selection. In the test with 31 samples, the X range saved as sel_001 returned 5 rows with selected and 26 with unselected. Variables → all retains all five columns. For trace, set Trace X variable → v0001 and Trace Y variable → v0003 explicitly. If you leave them blank, Run reports “Trace mode requires X/Y bindings.” When both are set, the analysis publishes the same rows using the two selected columns.

The second Scientific dataset 2D plot uses the six temperature samples published by Dataset Extract.
The second Scientific dataset 2D plot uses the six temperature samples published by Dataset Extract.