Obsidian
Probabilistic Geophysical Joint Inversion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
csv.hpp File Reference

Contains the interface of various IO interop with CSV. More...

#include <Eigen/Core>
#include <string>
#include <vector>
#include "string.hpp"
Include dependency graph for csv.hpp:
This graph shows which files directly or indirectly include this file:

Namespaces

 obsidian
 
 obsidian::io
 
 obsidian::io::csv
 For reading and writing csv files.
 

Functions

std::vector< std::vector
< std::string > > 
obsidian::io::csv::readRaw (const std::string &inCsvFilePath)
 Read csv file into a list of list of string fields.
 
void obsidian::io::csv::writeRaw (const std::string &outCsvFilePath, const std::vector< std::vector< std::string >> &data)
 Write list of list of string fields into a csv file.
 
std::pair< size_t, size_t > obsidian::io::csv::getRowMatrixDimensions (const std::vector< std::vector< std::string >> &data)
 Extracts row and column dimensions of data in list of list of string fields format. More...
 
template<typename ScalarType , int Rows = Eigen::Dynamic, int Cols = Eigen::Dynamic>
Eigen::Matrix< ScalarType,
Rows, Cols > 
obsidian::io::csv::read (const std::string &inCsvFilePath)
 Read csv file into a rectangular matrix. More...
 
template<typename ScalarType , int Rows = Eigen::Dynamic, int Cols = Eigen::Dynamic>
void obsidian::io::csv::write (const std::string &outCsvFilePath, const Eigen::Matrix< ScalarType, Rows, Cols > &data)
 Write Matrix into csv file.
 

Detailed Description

Contains the interface of various IO interop with CSV.

Author
Nahid Akbar
Date
2014-06-06
License:
General Public License version 3 or later