SG++-Doxygen-Documentation
|
Class implements the interface of DataAdapter for storing and restoring of input data into / from files in CSV-format. More...
Public Member Functions | |
def | __init__ (self, filename="") |
Constructor. More... | |
def | loadData (self, name="train", delimiter=', target_col=-1) |
Reads dataset from file. More... | |
def | loadSpecification (self, delimiter=') |
Loads attribute specification from file. More... | |
def | save (self, points, values=None, attributes=None) |
Store data into file. More... | |
Static Public Attributes | |
filename = None | |
Filename associated with data. More... | |
Class implements the interface of DataAdapter for storing and restoring of input data into / from files in CSV-format.
def python.data.CSVAdapter.CSVAdapter.__init__ | ( | self, | |
filename = "" |
|||
) |
Constructor.
filename | Filename as String |
References python.controller.InfoToFile.InfoToFile.filename, python.data.ARFFAdapter.ARFFAdapter.filename, and python.data.CSVAdapter.CSVAdapter.filename.
def python.data.CSVAdapter.CSVAdapter.loadData | ( | self, | |
name = "train" , |
|||
delimiter = ' , |
|||
target_col = -1 |
|||
) |
Reads dataset from file.
name | String for category of data set (train or test), default "train" |
delimiter | optional delimiter character. Default: ',' |
target_col | optional number of target column. Default: -1 |
References python.data.ARFFAdapter.ARFFAdapter.__gzOpen(), python.data.CSVAdapter.CSVAdapter.__gzOpen(), python.controller.InfoToFile.InfoToFile.filename, python.data.ARFFAdapter.ARFFAdapter.filename, and python.data.CSVAdapter.CSVAdapter.filename.
def python.data.CSVAdapter.CSVAdapter.loadSpecification | ( | self, | |
delimiter = ' |
|||
) |
Loads attribute specification from file.
References python.data.ARFFAdapter.ARFFAdapter.__gzOpen(), python.data.CSVAdapter.CSVAdapter.__gzOpen(), python.controller.InfoToFile.InfoToFile.filename, python.data.ARFFAdapter.ARFFAdapter.filename, and python.data.CSVAdapter.CSVAdapter.filename.
def python.data.CSVAdapter.CSVAdapter.save | ( | self, | |
points, | |||
values = None , |
|||
attributes = None |
|||
) |
Store data into file.
points | DataVector with points |
values | DataVector with values, default None |
attributes | dictionary with attributes of dataset, default None |
References python.data.ARFFAdapter.ARFFAdapter.__gzOpen(), python.data.CSVAdapter.CSVAdapter.__gzOpen(), python.controller.InfoToFile.InfoToFile.filename, python.data.ARFFAdapter.ARFFAdapter.filename, python.data.CSVAdapter.CSVAdapter.filename, and sgpp::combigrid.join().
|
static |
Filename associated with data.
Referenced by python.data.CSVAdapter.CSVAdapter.__init__(), python.data.DataSpecification.DataSpecification.__init__(), python.data.DataSpecification.DataSpecification.getFilename(), python.data.CSVAdapter.CSVAdapter.loadData(), python.data.CSVAdapter.CSVAdapter.loadSpecification(), python.data.CSVAdapter.CSVAdapter.save(), and python.data.DataSpecification.DataSpecification.setFilename().