@@ -72,26 +72,24 @@ fn get_list_of_rows_from_excel(file_path: &str) -> Result<Vec<Vec<String>>, Stri
7272}
7373
7474
75- /// Reads an Excel file in the **legacy phenopacket-store format**
76- /// and validates it into a structured 2D string matrix (`Vec<Vec<String>>`).
75+ /// Reads an Excel file and validates it into
76+ /// a structured 2D string matrix (`Vec<Vec<String>>`).
7777///
7878/// This function is specialized for early phenopacket-store input files,
7979/// which are expected to have:
80- /// - At least **3 rows** total (2 header rows + data).
81- /// - The **first two rows** (`row0`, `row1`) defining the column headers.
82- /// - Each data row having the **same number of fields** as the headers.
80+ /// - At least **2 rows** total (1 header rows + data).
81+ /// - Each data row having the **same number of fields** as the header.
8382///
8483/// # Behavior
8584/// - Delegates to [`get_list_of_rows_from_excel`] to extract raw cell values.
86- /// - Ensures the matrix has at least 3 rows; otherwise returns an error.
87- /// - Ensures the first two rows have the same number of fields (consistent headers).
88- /// - Ensures each subsequent row has the same number of fields as the headers.
85+ /// - Ensures the matrix has at least 2 rows; otherwise returns an error.
86+ /// - Ensures each subsequent row has the same number of fields as the header.
8987/// - Replaces any **empty cells** (only in data rows) with the literal `"na"`.
9088///
9189/// # Errors
9290/// Returns `Err(String)` in the following cases:
9391/// - The Excel file cannot be opened or parsed (from [`get_list_of_rows_from_excel`]).
94- /// - The file has fewer than 3 rows.
92+ /// - The file has fewer than 2 rows.
9593/// - The two header rows have different numbers of fields.
9694/// - Any data row has a different number of fields than the headers.
9795///
0 commit comments