Skip to content

Simple library to load numeric data to C++ vectors from csv files

Notifications You must be signed in to change notification settings

marekkolman/CPP_csv_reader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C++ csv reader

Simple library to load numeric data to C++ vectors from csv files.

The code is in csv_reader.h - that's the only file to be included when we want to read csvs.

The library loads csv as either

  • vector: vector<int>, vector<double>,
  • matrix: vector<vector<int>>, vector<vector<double>>

Use calls such as

vector<vector<double>> mat = readcsv_matrix<double>(R"(c:\temp\test\data.csv)", true);
vector<double> res = readcsv_vector<double>(R"(c:\temp\test\data.csv)", false);

By default header in the csv file is skipped for matrix data and NOT skipped for vector data.

About

Simple library to load numeric data to C++ vectors from csv files

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published