Skip to content

Commit deeb5c9

Browse files
committed
reverted changes from d-z.
1 parent 143e341 commit deeb5c9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+205
-264
lines changed

docs/StardustDocs/topics/DataColumn.md

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ See [how to create columns](createColumn.md)
77

88
### Properties
99
* `name: String` — name of the column, should be unique within containing dataframe
10-
* `path: ColumnPath` — path to the column, depends on the way column was retrieved from the dataframe
10+
* `path: ColumnPath` — path to the column, depends on the way column was retrieved from dataframe
1111
* `type: KType` — type of elements in the column
12-
* `hasNulls: Boolean` — flag indicating whether a column contains `null` values
12+
* `hasNulls: Boolean` — flag indicating whether column contains `null` values
1313
* `values: Iterable<T>` — column data
1414
* `size: Int` — number of elements in the column
1515

@@ -24,7 +24,7 @@ It can store values of primitive (integers, strings, decimals etc.) or reference
2424

2525
#### ColumnGroup
2626

27-
Container for nested columns. It is used to create column hierarchy.
27+
Container for nested columns. Is used to create column hierarchy.
2828

2929
#### FrameColumn
3030

@@ -36,11 +36,7 @@ Special case of [`ValueColumn`](#valuecolumn) that stores other [`DataFrames`](D
3636

3737
## Column accessors
3838

39-
`ColumnAccessors` are used for [typed data access](columnAccessorsApi.md) in [`DataFrame`](DataFrame.md).
40-
`ColumnAccessor`
41-
stores column [`name`](#properties) (for top-level columns) or column path (for nested columns),
42-
has type argument that corresponds to [`type`](#properties) of the column,
43-
but it doesn't contain any actual data.
39+
`ColumnAccessors` are used for [typed data access](columnAccessorsApi.md) in [`DataFrame`](DataFrame.md). `ColumnAccessor` stores column [`name`](#properties) (for top-level columns) or column path (for nested columns), has type argument that corresponds to [`type`](#properties) of thep column, but it doesn't contain any actual data.
4440

4541
<!---FUN columnAccessorsUsage-->
4642

@@ -49,11 +45,11 @@ val age by column<Int>()
4945

5046
// Access fourth cell in the "age" column of dataframe `df`.
5147
// This expression returns `Int` because variable `age` has `ColumnAccessor<Int>` type.
52-
// If dataframe `df` has no column "age" or column "age" has a type which is incompatible with `Int`,
53-
// a runtime exception will be thrown.
48+
// If dataframe `df` has no column "age" or column "age" has type which is incompatible with `Int`,
49+
// runtime exception will be thrown.
5450
df[age][3] + 5
5551

56-
// Access the first cell in the "age" column of dataframe `df`.
52+
// Access first cell in the "age" column of dataframe `df`.
5753
df[0][age] * 2
5854

5955
// Returns new dataframe sorted by age column (ascending)
@@ -78,7 +74,7 @@ val name by column<String>()
7874

7975
<!---END-->
8076

81-
To assign a column name explicitly, pass it as an argument.
77+
To assign column name explicitly, pass it as an argument.
8278

8379
<!---FUN createColumnAccessorRenamed-->
8480

@@ -110,7 +106,7 @@ val firstName by name.column<String>()
110106

111107
<!---END-->
112108

113-
You can also create a virtual accessor that doesn't point to a real column but computes some expression on every data access:
109+
You can also create virtual accessor that doesn't point to a real column but computes some expression on every data access:
114110

115111
<!---FUN columnAccessorComputed-->
116112
<tabs>

docs/StardustDocs/topics/DataRow.md

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@
1010
* `next(): DataRow?` — next row (`null` for the last row)
1111
* `diff { rowExpression }: T` — difference between results of [row expression](#row-expressions) calculated for current and previous rows
1212
* `values(): List<Any?>` — list of all cell values from the current row
13-
* `valuesOf<T>(): List<T>` — list of values of a given type
13+
* `valuesOf<T>(): List<T>` — list of values of given type
1414
* `columnsCount(): Int` — number of columns
1515
* `columnNames(): List<String>` — list of all column names
1616
* `columnTypes(): List<KType>` — list of all column types
1717
* `namedValues(): List<NameValuePair<Any?>>` — list of name-value pairs where `name` is a column name and `value` is cell value
18-
* `namedValuesOf<T>(): List<NameValuePair<T>>` — list of name-value pairs where value has given a type
18+
* `namedValuesOf<T>(): List<NameValuePair<T>>` — list of name-value pairs where value has given type
1919
* `transpose(): DataFrame<NameValuePair<*>>` — dataframe of two columns: `name: String` is column names and `value: Any?` is cell values
2020
* `transposeTo<T>(): DataFrame<NameValuePair<T>>`— dataframe of two columns: `name: String` is column names and `value: T` is cell values
2121
* `getRow(Int): DataRow` — row from [`DataFrame`](DataFrame.md) by row index
@@ -54,7 +54,7 @@ Row condition is a special case of [row expression](#row-expressions) that retur
5454
// Row condition is used to filter rows by index
5555
df.filter { index() % 5 == 0 }
5656

57-
// Row condition is used to drop rows where `age` is the same as in the previous row
57+
// Row condition is used to drop rows where `age` is the same as in previous row
5858
df.drop { diff { age } == 0 }
5959

6060
// Row condition is used to filter rows for value update
@@ -76,11 +76,10 @@ The following [statistics](summaryStatistics.md) are available for `DataRow`:
7676
* `rowStd`
7777
* `rowMedian`
7878

79-
These statistics will be applied only to values of appropriate types, and incompatible values will be ignored.
80-
For example, if [`DataFrame`](DataFrame.md) has columns of a type `String` and `Int`,
81-
`rowSum()` will successfully compute a sum of `Int` values in a row and ignore `String` values.
79+
These statistics will be applied only to values of appropriate types and incompatible values will be ignored.
80+
For example, if [`DataFrame`](DataFrame.md) has columns of type `String` and `Int`, `rowSum()` will successfully compute sum of `Int` values in a row and ignore `String` values.
8281

83-
To apply statistics only to values of a particular type, use `-Of` versions:
82+
To apply statistics only to values of particular type use `-Of` versions:
8483
* `rowMaxOf<T>`
8584
* `rowMinOf<T>`
8685
* `rowSumOf<T>`

docs/StardustDocs/topics/KPropertiesApi.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<!---IMPORT org.jetbrains.kotlinx.dataframe.samples.api.ApiLevels-->
44

55
[`DataFrame`](DataFrame.md) can be used as an intermediate structure for data transformation between two data formats.
6-
If either source or destination is a Kotlin object, e.g., data class, it is convenient to use its properties
6+
If either source or destination is a Kotlin object, e.g. data class, it is convenient to use its properties
77
for typed data access in [`DataFrame`](DataFrame.md).
88
This can be done using `::` expression that provides [property references](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.reflect/-k-property/)
99

@@ -31,7 +31,7 @@ val passengers = DataFrame.read("titanic.csv")
3131
<!---END-->
3232

3333
By default, [`DataFrame`](DataFrame.md) uses `name` and `returnType` of `KProperty` for typed access to data.
34-
When the column name differs from the property name, use `@ColumnName` annotation:
34+
When column name differs from property name, use `@ColumnName` annotation:
3535

3636
<!---FUN kproperties2-->
3737

@@ -49,4 +49,4 @@ val passengers = DataFrame.read("titanic.csv")
4949

5050
<!---END-->
5151

52-
The `titanic.csv` file can be found [here](https://github.com/Kotlin/dataframe/blob/master/data/titanic.csv).
52+
The `titanic.csv` file could be found [here](https://github.com/Kotlin/dataframe/blob/master/data/titanic.csv).

docs/StardustDocs/topics/distinct.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ df.distinct()
1414
<dataFrame src="org.jetbrains.kotlinx.dataframe.samples.api.Access.distinct.html"/>
1515
<!---END-->
1616

17-
If columns are specified, the resulting [`DataFrame`](DataFrame.md) will have only given columns with distinct values.
17+
If columns are specified, resulting [`DataFrame`](DataFrame.md) will have only given columns with distinct values.
1818

1919
<!---FUN distinctColumns-->
2020
<tabs>

docs/StardustDocs/topics/duplicate.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,12 @@ DataRow.duplicate(n): DataFrame
66
```
77

88
Returns [`FrameColumn`](DataColumn.md#framecolumn) with original [`DataFrame`](DataFrame.md) repeated `n` times.
9-
The resulting [`FrameColumn`](DataColumn.md#framecolumn) will have an empty [`name`](DataColumn.md#properties).
9+
Resulting [`FrameColumn`](DataColumn.md#framecolumn) will have an empty [`name`](DataColumn.md#properties).
1010
```text
1111
DataFrame.duplicate(n): FrameColumn
1212
```
1313

14-
Returns [`DataFrame`](DataFrame.md)
15-
where rows that satisfy the given [condition](DataRow.md#row-conditions) are repeated `n` times.
16-
If `rowCondition` is not specified, all rows will be duplicated.
14+
Returns [`DataFrame`](DataFrame.md) where rows that satisfy to the given [condition](DataRow.md#row-conditions) are repeated `n` times. If `rowCondition` is not specified all rows will be duplicated.
1715
```text
1816
DataFrame.duplicateRows(n) [ { rowCondition } ]: DataFrame
1917
```

docs/StardustDocs/topics/extensionPropertiesApi.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
<!---IMPORT org.jetbrains.kotlinx.dataframe.samples.api.ApiLevels-->
44

5-
When [`DataFrame`](DataFrame.md) is used within Jupyter Notebooks or Datalore with Kotlin Kernel,
6-
after every cell execution all new global variables of type DataFrame are analyzed and replaced
5+
When [`DataFrame`](DataFrame.md) is used within Jupyter Notebooks or Datalore with Kotlin Kernel,
6+
after every cell execution all new global variables of type DataFrame are analyzed and replaced
77
with typed [`DataFrame`](DataFrame.md) wrapper with auto-generated extension properties for data access:
88

99
<!---FUN extensionProperties1-->
@@ -26,14 +26,11 @@ df.add("lastName") { name.split(",").last() }
2626

2727
<!---END-->
2828

29-
The `titanic.csv` file can be found [here](https://github.com/Kotlin/dataframe/blob/master/data/titanic.csv).
29+
The `titanic.csv` file could be found [here](https://github.com/Kotlin/dataframe/blob/master/data/titanic.csv).
3030

31-
In notebooks, extension properties are generated for [`DataSchema`](schemas.md)
32-
that is extracted from [`DataFrame`](DataFrame.md)
31+
In notebooks, extension properties are generated for [`DataSchema`](schemas.md) that is extracted from [`DataFrame`](DataFrame.md)
3332
instance after REPL line execution.
34-
After that [`DataFrame`](DataFrame.md) variable is typed with its own [`DataSchema`](schemas.md),
35-
so only valid extension properties corresponding to actual columns in DataFrame will be allowed by the compiler
36-
and suggested by completion.
33+
After that [`DataFrame`](DataFrame.md) variable is typed with its own [`DataSchema`](schemas.md), so only valid extension properties corresponding to actual columns in DataFrame will be allowed by the compiler and suggested by completion.
3734

3835
Extension properties can be generated in IntelliJ IDEA using the [Kotlin Dataframe Gradle plugin](schemasGradle.md#configuration).
3936

docs/StardustDocs/topics/filter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ df.filter { "age"<Int>() > 18 && "name"["firstName"]<String>().startsWith("A") }
3838

3939
## filterBy
4040

41-
Returns [`DataFrame`](DataFrame.md) with rows that have value `true` in given column of a type `Boolean`.
41+
Returns [`DataFrame`](DataFrame.md) with rows that have value `true` in given column of type `Boolean`.
4242

4343
<!---FUN filterBy-->
4444
<tabs>

docs/StardustDocs/topics/first.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
[//]: # (title: first)
22

3-
Returns the first [row](DataRow.md) that matches the given [condition](DataRow.md#row-conditions),
4-
or throws exception if there are no matching rows.
3+
Returns the first [row](DataRow.md) that matches the given [condition](DataRow.md#row-conditions), or throws exception if there is no matching rows.
54

65
## firstOrNull
76

8-
Returns the first [row](DataRow.md) that matches the given [condition](DataRow.md#row-conditions),
9-
or `null` if there are no matching rows.
7+
Returns the first [row](DataRow.md) that matches the given [condition](DataRow.md#row-conditions), or `null` if there is no matching rows.

docs/StardustDocs/topics/gather.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<!---IMPORT org.jetbrains.kotlinx.dataframe.samples.api.Modify-->
44

5-
Converts several columns into two columns `key` and `value`. `Key` column will contain names of original columns, `value` column will contain values from original columns.
5+
Converts several columns into two columns `key` and `value`. `key` column will contain names of original columns, `value` column will contain values from original columns.
66

77
This operation is reverse to [pivot](pivot.md)
88

@@ -24,7 +24,7 @@ valueTransform: (value) -> R
2424
See [column selectors](ColumnSelectors.md)
2525

2626
Configuration options:
27-
* `explodeLists` — gathered values of a type [`List`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/) will be exploded into their elements, so `where`, `cast`, `notNull` and `mapValues` will be applied to list elements instead of lists themselves
27+
* `explodeLists` — gathered values of type [`List`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/) will be exploded into their elements, so `where`, `cast`, `notNull` and `mapValues` will be applied to list elements instead of lists themselves
2828
* `cast` — inform compiler about the expected type of gathered elements. This type will be passed to `where` and `mapKeys` lambdas
2929
* `notNull` — skip gathered `null` values
3030
* `where` — filter gathered values

docs/StardustDocs/topics/getColumn.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22

33
<!---IMPORT org.jetbrains.kotlinx.dataframe.samples.api.Access-->
44

5-
Return column by column name or [column selector](ColumnSelectors.md) as [`DataColumn`](DataColumn.md).
6-
Throw exception if the requested column doesn't exist.
5+
Return column by column name or [column selector](ColumnSelectors.md) as [`DataColumn`](DataColumn.md). Throws exception if requested column doesn't exist.
76

87
<!---FUN getColumn-->
98
<tabs>
@@ -65,8 +64,7 @@ df.getColumnOrNull("age")
6564

6665
## getColumnGroup
6766

68-
Return top-level column by column name or [column selector](ColumnSelectors.md) as [`ColumnGroup`](DataColumn.md#columngroup).
69-
Throws exception if the requested column doesn't exist or is not a `ColumnGroup`.
67+
Return top-level column by column name or [column selector](ColumnSelectors.md) as [`ColumnGroup`](DataColumn.md#columngroup). Throws exception if requested column doesn't exist or is not a `ColumnGroup`.
7068

7169
<!---FUN getColumnGroup-->
7270
<tabs>
@@ -97,7 +95,7 @@ df.getColumnGroup("name")
9795

9896
## getColumns
9997

100-
Return a list of selected columns.
98+
Return list of selected columns.
10199

102100
<!---FUN getColumns-->
103101
<tabs>

0 commit comments

Comments
 (0)