Documentation ¶
Index ¶
- func ToFloat64(val interface{}) (float64, bool)
- type DataFrame
- func NewDataFrame(data interface{}) (*DataFrame, error)
- func ReadCSVFromFile(csvFilePath string, v interface{}) (*DataFrame, error)
- func ReadCSVFromString(csvData string, v interface{}) (*DataFrame, error)
- func ReadJSONFromFile(jsonFilePath string, v interface{}) (*DataFrame, error)
- func ReadJSONFromString(jsonData string, v interface{}) (*DataFrame, error)
- func (df *DataFrame) Corr() (*DataFrame, error)
- func (df *DataFrame) DeleteRow(id int) error
- func (df *DataFrame) Display() error
- func (df *DataFrame) FromStructs(data interface{}) error
- func (df *DataFrame) Head(n ...int) ([]map[string]interface{}, error)
- func (df *DataFrame) Info() error
- func (df *DataFrame) InsertRow(id int, row interface{})
- func (df *DataFrame) Join(other *DataFrame, joinType string, keys []string) (*DataFrame, error)
- func (df *DataFrame) Loc(indices ...int) ([]map[string]interface{}, error)
- func (df *DataFrame) ReadRow(id int) (interface{}, error)
- func (df *DataFrame) Tail(n ...int) ([]map[string]interface{}, error)
- func (df *DataFrame) ToCSV(csvFilePath string) error
- func (df *DataFrame) ToMatrix() ([][]float64, []string, error)
- func (df *DataFrame) UpdateRow(id int, newValues map[string]interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DataFrame ¶
type DataFrame struct { Name string StructType reflect.Type Data map[int]interface{} Index *db.BPlusTree // Use the BPlusTree from db package // contains filtered or unexported fields }
func NewDataFrame ¶
func ReadCSVFromFile ¶
ReadCSVFromFile takes a CSV file path and a pointer to a struct, populates the struct with the CSV data.
func ReadCSVFromString ¶
ReadCSVFromString takes a CSV string and a pointer to a struct, populates the struct with the CSV data.
func ReadJSONFromFile ¶
ReadJSONFromFile takes a JSON file path and a pointer to a struct, populates the struct with the JSON data.
func ReadJSONFromString ¶
ReadJSONFromString takes a JSON string and a pointer to a slice of structs, populates the slice with the JSON data.
func (*DataFrame) Corr ¶
Corr calculates the correlation matrix for the numerical columns in the DataFrame.
func (*DataFrame) FromStructs ¶
FromStructs creates a DataFrame from a slice of structs.
Click to show internal directories.
Click to hide internal directories.