Go to the source code of this file.
|
char *** | cs_file_csv_parse (const char *file_name, const char *separator, const int n_headers, const int n_columns, const int *col_idx, const bool ignore_missing_tokens, int *n_rows, int *n_cols) |
| Parse a csv file and export to a dataset (char ***). More...
|
|
◆ cs_file_csv_parse()
char*** cs_file_csv_parse |
( |
const char * |
file_name, |
|
|
const char * |
separator, |
|
|
const int |
n_headers, |
|
|
const int |
n_columns, |
|
|
const int * |
col_idx, |
|
|
const bool |
ignore_missing_tokens, |
|
|
int * |
n_rows, |
|
|
int * |
n_cols |
|
) |
| |
Parse a csv file and export to a dataset (char ***).
- Parameters
-
[in] | file_name | Name of the file to read |
[in] | separator | Separator (int) |
[in] | n_headers | Number of headers (to ignore during import) |
[in] | n_columns | Number of columns to read. -1 if all columns are to be read |
[in] | col_idx | Array of indices of columns to read (if n_columns != -1) |
[in] | ignore_missing_tokens | Ignore missing tokens (NULL) |
[in] | n_rows | Pointer to number of rows in file |
[in] | n_cols | Pointer to number of columns in file |
- Returns
- Pointer to newly created dataseti. Needs to be deallocated by caller