Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix table display for remaining toDataFrame examples
  • Loading branch information
koperagen committed Oct 23, 2025
commit b51f36aaf0b3d388e64f14c5a03e9d3249754377
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,10 @@ import org.jetbrains.kotlinx.dataframe.api.toColumn
import org.jetbrains.kotlinx.dataframe.api.toColumnOf
import org.jetbrains.kotlinx.dataframe.api.toDataFrame
import org.jetbrains.kotlinx.dataframe.api.value
import org.jetbrains.kotlinx.dataframe.columns.ColumnKind
import org.jetbrains.kotlinx.dataframe.explainer.TransformDataFrameExpressions
import org.jetbrains.kotlinx.dataframe.kind
import org.jetbrains.kotlinx.dataframe.type
import org.junit.Test
import java.io.File
import kotlin.random.Random as KotlinRandom
import kotlin.reflect.typeOf

class Create : TestBase() {

Expand Down Expand Up @@ -419,11 +415,6 @@ class Create : TestBase() {

val df = students.toDataFrame(maxDepth = 1)
// SampleEnd
df.columnsCount() shouldBe 3
df.rowsCount() shouldBe 2
df["name"].kind shouldBe ColumnKind.Group
df["name"]["firstName"].type() shouldBe typeOf<String>()
df["scores"].kind shouldBe ColumnKind.Frame
}

@Test
Expand Down Expand Up @@ -458,12 +449,6 @@ class Create : TestBase() {
}
}
// SampleEnd
df.columnsCount() shouldBe 5
df.rowsCount() shouldBe 2
df["name"].kind shouldBe ColumnKind.Value
df["name"].type shouldBe typeOf<Name>()
df["scores"].kind shouldBe ColumnKind.Frame
df["summary"]["min score"].values() shouldBe listOf(3, 5)
}

@Test
Expand Down
Loading