Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support list type as series' element #178

Open
ariefrahmansyah opened this issue Jan 26, 2022 · 0 comments
Open

Support list type as series' element #178

ariefrahmansyah opened this issue Jan 26, 2022 · 0 comments

Comments

@ariefrahmansyah
Copy link

Currently, gota only supports four basic types (bool, float, int, string) but not for list types ([]bool, []float, []int, []string).

Any plan to support list types?

Example:

	df := dataframe.New(
		series.New([]string{"b", "a"}, series.String, "COL.1"),
		series.New([]int{1, 2}, series.Int, "COL.2"),
		series.New([]float64{3.0, 4.0}, series.Float, "COL.3"),
		series.New([][]int{{1, 2}, {3, 4}}, series.IntList, "COL.4"),
	)
	fmt.Println(df)

	// Output:
	// [2x4] DataFrame
	//
	//     COL.1    COL.2 COL.3    COL.4
	//  0: b        1     3.000000 [1 2]
	//  1: a        2     4.000000 [3 4]
	//     <string> <int> <float>  <int_list>

It's related to #102

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant