diff --git a/DSL/de.unibonn.simpleml/build.gradle.kts b/DSL/de.unibonn.simpleml/build.gradle.kts index 087913b30..2f4f93738 100644 --- a/DSL/de.unibonn.simpleml/build.gradle.kts +++ b/DSL/de.unibonn.simpleml/build.gradle.kts @@ -68,6 +68,10 @@ val koverExcludes = listOf( ) tasks { + build { + dependsOn(project.tasks.named("generateStdlibDocumentation")) + } + compileJava { dependsOn(rootProject.tasks.named("generateXtextLanguage")) } @@ -122,10 +126,14 @@ tasks.register("generateStdlibDocumentation") { group = "documentation" description = "Generate documentation for the standard library." + val inputDirectory = project.file("src/main/resources/stdlib") + val outputDirectory = rootProject.file("../docs/Stdlib/API").absolutePath + + inputs.dir(inputDirectory) + outputs.dirs(outputDirectory) + dependsOn(sourceSets.main.get().runtimeClasspath) classpath = sourceSets.main.get().runtimeClasspath.filter { it.exists() } mainClass.set("de.unibonn.simpleml.stdlibDocumentation.MainKt") - - val outputDirectory = rootProject.file("../docs/Stdlib/API").absolutePath args = listOf(outputDirectory) } diff --git a/DSL/de.unibonn.simpleml/src/main/kotlin/de/unibonn/simpleml/stdlibDocumentation/DocumentationGenerator.kt b/DSL/de.unibonn.simpleml/src/main/kotlin/de/unibonn/simpleml/stdlibDocumentation/DocumentationGenerator.kt index 88c8c13c0..45a231d40 100644 --- a/DSL/de.unibonn.simpleml/src/main/kotlin/de/unibonn/simpleml/stdlibDocumentation/DocumentationGenerator.kt +++ b/DSL/de.unibonn.simpleml/src/main/kotlin/de/unibonn/simpleml/stdlibDocumentation/DocumentationGenerator.kt @@ -53,6 +53,7 @@ private val autogenWarning = """ * @param outputDirectory Where to place the created files. */ fun EObject.generateDocumentation(outputDirectory: Path) { + outputDirectory.toFile().deleteRecursively() outputDirectory.createDirectories() val packagesToDeclarations: Map> = allGlobalDeclarations() @@ -110,7 +111,7 @@ private fun createPackageDocumentation( appendLine("# Package `$packageName`") - appendLine("$prefix") + appendLine(prefix) // Table of contents if (annotations.isNotEmpty() || classes.isNotEmpty() || enums.isNotEmpty() || globalFunctions.isNotEmpty()) { diff --git a/DSL/de.unibonn.simpleml/src/test/resources/validation/declarations/imports/unresolvedNamespace.smltest b/DSL/de.unibonn.simpleml/src/test/resources/validation/declarations/imports/unresolvedNamespace.smltest index 6d271aa78..2de332ffe 100644 --- a/DSL/de.unibonn.simpleml/src/test/resources/validation/declarations/imports/unresolvedNamespace.smltest +++ b/DSL/de.unibonn.simpleml/src/test/resources/validation/declarations/imports/unresolvedNamespace.smltest @@ -1,15 +1,15 @@ package tests.unresolvedNamespace -// semantic_error "No declaration with qualified name 'simpleml.models.Model' exists." -import »simpleml.models.Model« -// no_semantic_error "No declaration with qualified name 'simpleml.model.Model' exists." -import »simpleml.model.Model« +// semantic_error "No declaration with qualified name 'simpleml.langs.Any' exists." +import »simpleml.langs.Any« +// no_semantic_error "No declaration with qualified name 'simpleml.lang.Any' exists." +import »simpleml.lang.Any« // no_semantic_error "No declaration with qualified name 'tests.unresolvedNamespace.C' exists." import »tests.unresolvedNamespace.C« -// semantic_error "No package with qualified name 'simpleml.models' exists." -import »simpleml.models.*« +// semantic_error "No package with qualified name 'simpleml.langs' exists." +import »simpleml.langs.*« // no_semantic_error "No package with qualified name 'simpleml.model' exists." -import »simpleml.model.*« +import »simpleml.lang.*« class C diff --git a/docs/Stdlib/API/simpleml_collections.md b/docs/Stdlib/API/simpleml_collections.md deleted file mode 100644 index ad740bd8c..000000000 --- a/docs/Stdlib/API/simpleml_collections.md +++ /dev/null @@ -1,55 +0,0 @@ -# Package `simpleml.collections` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`List`](#class-List) - * [`Map`](#class-Map) -* Global functions - * [`listOf`](#global-function-listOf) - ----------- - - - -## Class `List` -_No description available._ - -**Constructor:** _Class has no constructor._ - - ----------- - - - -## Class `Map` -_No description available._ - -**Constructor:** _Class has no constructor._ - - -## Global Functions - - - -## Global Function `listOf` -_No description available._ - -**Parameters:** -* `vararg elements: Int` - _No description available._ - -**Results:** -* `list: List` - _No description available._ - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_dataset.md b/docs/Stdlib/API/simpleml_dataset.md deleted file mode 100644 index fd29665fd..000000000 --- a/docs/Stdlib/API/simpleml_dataset.md +++ /dev/null @@ -1,348 +0,0 @@ -# Package `simpleml.dataset` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`AttributeTransformer`](#class-AttributeTransformer) - * [`Dataset`](#class-Dataset) - * [`DayOfTheYearTransformer`](#class-DayOfTheYearTransformer) - * [`Instance`](#class-Instance) - * [`StandardNormalizer`](#class-StandardNormalizer) - * [`StandardScaler`](#class-StandardScaler) - * [`TimestampTransformer`](#class-TimestampTransformer) - * [`WeekDayTransformer`](#class-WeekDayTransformer) - * [`WeekendTransformer`](#class-WeekendTransformer) -* Global functions - * [`joinTwoDatasets`](#global-function-joinTwoDatasets) - * [`loadDataset`](#global-function-loadDataset) - * [`readDataSetFromCSV`](#global-function-readDataSetFromCSV) - ----------- - - - -## Class `AttributeTransformer` -_No description available._ - -**Constructor:** _Class has no constructor._ - - ----------- - - - -## Class `Dataset` -A dataset with its data instances (e.g., rows and columns) - -**Constructor:** _Class has no constructor._ - -### `addAttribute` (Instance Method ) -Add a new attribute to the dataset with values according to a transformation function - -**Parameters:** -* `newAttributeId: String` - The ID of the new attribute -* `transformer: AttributeTransformer` - The attribute transformer to be used. -* `newAttributeLabel: String? = null` - The name of the new attribute. - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `dropAllMissingValues` (Instance Method ) -Drops instances with missing values - -**Parameters:** _None expected._ - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `dropAttribute` (Instance Method ) -Drop a single attribute from a dataset - -**Parameters:** -* `attribute: String` - The attribute to drop from the dataset - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `dropAttributes` (Instance Method ) -Drop attributes from a dataset - -**Parameters:** -* `vararg attributes: String` - The list of attributes to drop from the dataset - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `dropMissingValues` (Instance Method ) -Drops instances with missing values in the specified attribute - -**Parameters:** -* `attribute: String` - Attribute whose empty values are dropped - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `exportDataAsFile` (Instance Method ) -Export any dataset to CSV file - -**Parameters:** -* `filePath: String` - _No description available._ - -**Results:** _None returned._ - -### `filterInstances` (Instance Method ) -Remove instances in a dataset according to a filter function - -**Parameters:** -* `filterFunc: (instance: Instance) -> shouldKeep: Boolean` - The filter function that returns either True (keep) or False (remove) for each instance - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `getRow` (Instance Method ) -Get a specific row of a dataset - -**Parameters:** -* `rowNumber: Int` - The number of the row to be retrieved - -**Results:** -* `instance: Instance` - The specified row - -### `keepAttribute` (Instance Method ) -Retain a single attribute of a dataset - -**Parameters:** -* `attribute: String` - The attribute to retain in the dataset - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `keepAttributes` (Instance Method ) -Retain attributes of a dataset - -**Parameters:** -* `vararg attributes: String` - The list of attributes to retain in the dataset - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `sample` (Instance Method ) -Create a sample of a dataset - -**Parameters:** -* `nInstances: Int` - Number of instances in the sample - -**Results:** -* `sample: Dataset` - The sampled dataset - -### `setTargetAttribute` (Instance Method ) -Set the specified attribute as prediction target - -**Parameters:** -* `targetAttribute: String` - The attribute to be predicted later on - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `splitIntoTrainAndTest` (Instance Method ) -Split a dataset in a train and a test dataset - -**Parameters:** -* `trainRatio: Float` - The percentage of instances to keep in the training dataset -* `randomState: Int? = null` - A random seed to use for splitting - -**Results:** -* `train: Dataset` - The training dataset -* `test: Dataset` - The test dataset - -### `splitIntoTrainAndTestAndLabels` (Instance Method ) -Split a dataset into four datasets: train/test and labels/features. Requires that a target attribute has been set before via setTargetAttribute() - -**Parameters:** -* `trainRatio: Float` - The percentage of instances to keep in the training dataset -* `randomState: Int? = null` - A random seed to use for splitting - -**Results:** -* `xTrain: Dataset` - Features of the training dataset -* `xTest: Dataset` - Features of the test dataset -* `yTrain: Dataset` - Labels of the training dataset -* `yTest: Dataset` - Labels of the test dataset - -### `transform` (Instance Method ) -Update existing attribute with values according to a transformation function - -**Parameters:** -* `attributeId: String` - The ID of the attribute to be replaced -* `transformer: AttributeTransformer` - The attribute transformer to be used - -**Results:** -* `dataset: Dataset` - The updated dataset - -### `transformDatatypes` (Instance Method ) -Convert all column values into numbers - -**Parameters:** _None expected._ - -**Results:** -* `dataset: Dataset` - The updated dataset - - ----------- - - - -## Class `DayOfTheYearTransformer` -An attribute transformer to convert a date attribute to its day in the year. - -**Constructor parameters:** -* `attributeId: String` - The ID of the date attribute. - - ----------- - - - -## Class `Instance` -A single instance (e.g., row) of a dataset - -**Constructor:** _Class has no constructor._ - -### `getValue` (Instance Method ) -Return a specific value of the instance - -**Parameters:** -* `attribute: String` - The attribute whose value is returned - -**Results:** -* `value: Any` - The specified value - - ----------- - - - -## Class `StandardNormalizer` -A normalizer to normalize dataset values - -**Constructor parameters:** _None expected._ - -### `normalize` (Instance Method ) -Normalize all numeric values in the dataset - -**Parameters:** -* `dataset: Dataset` - Dataset to be normalized - -**Results:** -* `normalizedDataset: Dataset` - The normalized dataset - - ----------- - - - -## Class `StandardScaler` -A scaler to scale dataset values - -**Constructor parameters:** _None expected._ - -### `scale` (Instance Method ) -Scale all numeric values in the dataset - -**Parameters:** -* `dataset: Dataset` - Dataset to be scaled - -**Results:** -* `scaledDataset: Dataset` - The scaled dataset - - ----------- - - - -## Class `TimestampTransformer` -An attribute transformer to convert a date attribute to its timestamp. - -**Constructor parameters:** -* `attributeId: String` - The ID of the date attribute. - - ----------- - - - -## Class `WeekDayTransformer` -An attribute transformer to convert a date attribute to its weekday (as a string). - -**Constructor parameters:** -* `attributeId: String` - The ID of the date attribute. - - ----------- - - - -## Class `WeekendTransformer` -An attribute transformer to convert a date attribute to whether the date is on the weekend or not. - -**Constructor parameters:** -* `attributeId: String` - The ID of the date attribute. - - -## Global Functions - - - -## Global Function `joinTwoDatasets` -Join two datasets into one dataset - -**Parameters:** -* `dataset1: Dataset` - The first dataset -* `dataset2: Dataset` - The second dataset -* `attributeId1: String` - The attribute of the first dataset to use for the join -* `attributeId2: String` - The attribute of the second dataset to use for the join -* `suffix1: String` - The suffix to be attached to the attribute names of the first dataset -* `suffix2: String` - The suffix to be attached to the attribute names of the second dataset - -**Results:** -* `dataset: Dataset` - The joined dataset - - - -## Global Function `loadDataset` -Load a dataset via its identifier - -**Parameters:** -* `datasetID: String` - Identifier of the dataset - -**Results:** -* `dataset: Dataset` - The loaded dataset - - - -## Global Function `readDataSetFromCSV` -Load a dataset from a CSV file - -**Parameters:** -* `fileName: String` - Path and name of the CSV file -* `datasetId: String` - Identifier of the dataset -* `separator: String` - Separator used in the file -* `hasHeader: String` - True, if the file has a header row -* `nullValue: String` - String that should be parsed as missing value -* `datasetName: String` - Name of the dataset -* `coordinateSystem: Int = 3857` - Coordinate system used in the geometry columns of the dataset - -**Results:** -* `dataset: Dataset` - The loaded dataset - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_metrics.md b/docs/Stdlib/API/simpleml_metrics.md deleted file mode 100644 index 20e5702e0..000000000 --- a/docs/Stdlib/API/simpleml_metrics.md +++ /dev/null @@ -1,152 +0,0 @@ -# Package `simpleml.metrics` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Global functions - * [`accuracy`](#global-function-accuracy) - * [`averagePrecision`](#global-function-averagePrecision) - * [`balancedAccuracy`](#global-function-balancedAccuracy) - * [`meanAbsoluteError`](#global-function-meanAbsoluteError) - * [`meanSquaredError`](#global-function-meanSquaredError) - * [`meanSquaredLogError`](#global-function-meanSquaredLogError) - * [`medianAbsoluteError`](#global-function-medianAbsoluteError) - * [`precision`](#global-function-precision) - * [`r2`](#global-function-r2) - * [`recall`](#global-function-recall) - ----------- - -## Global Functions - - - -## Global Function `accuracy` -Compute the accuracy between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `averagePrecision` -Compute the average precision between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `balancedAccuracy` -Compute the balanced accuracy between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `meanAbsoluteError` -Compute the mean absolute error between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `meanSquaredError` -Compute the mean squared error between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `meanSquaredLogError` -Compute the mean squared log error between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `medianAbsoluteError` -Compute the median absolute error between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `precision` -Compute the precision between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `r2` -Compute the coefficient of determination (R2 score) between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `recall` -Compute the recall between two datasets - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_metrics_classification.md b/docs/Stdlib/API/simpleml_metrics_classification.md deleted file mode 100644 index 03aa9dd1d..000000000 --- a/docs/Stdlib/API/simpleml_metrics_classification.md +++ /dev/null @@ -1,87 +0,0 @@ -# Package `simpleml.metrics.classification` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Global functions - * [`accuracy`](#global-function-accuracy) - * [`averagePrecision`](#global-function-averagePrecision) - * [`balancedAccuracy`](#global-function-balancedAccuracy) - * [`precision`](#global-function-precision) - * [`recall`](#global-function-recall) - ----------- - -## Global Functions - - - -## Global Function `accuracy` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `averagePrecision` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `balancedAccuracy` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `precision` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `recall` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_metrics_regression.md b/docs/Stdlib/API/simpleml_metrics_regression.md deleted file mode 100644 index dfc8a8902..000000000 --- a/docs/Stdlib/API/simpleml_metrics_regression.md +++ /dev/null @@ -1,87 +0,0 @@ -# Package `simpleml.metrics.regression` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Global functions - * [`meanAbsoluteError`](#global-function-meanAbsoluteError) - * [`meanSquaredError`](#global-function-meanSquaredError) - * [`meanSquaredLogError`](#global-function-meanSquaredLogError) - * [`medianAbsoluteError`](#global-function-medianAbsoluteError) - * [`r2`](#global-function-r2) - ----------- - -## Global Functions - - - -## Global Function `meanAbsoluteError` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `meanSquaredError` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `meanSquaredLogError` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `medianAbsoluteError` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - - - -## Global Function `r2` -_No description available._ - -**Parameters:** -* `yTrue: Dataset` - _No description available._ -* `yPred: Dataset` - _No description available._ - -**Results:** -* `score: Float` - _No description available._ - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_model.md b/docs/Stdlib/API/simpleml_model.md deleted file mode 100644 index e20e7cfee..000000000 --- a/docs/Stdlib/API/simpleml_model.md +++ /dev/null @@ -1,40 +0,0 @@ -# Package `simpleml.model` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`Estimator`](#class-Estimator) - * [`Model`](#class-Model) - ----------- - - - -## Class `Estimator` -_No description available._ - -**Constructor:** _Class has no constructor._ - - ----------- - - - -## Class `Model` -_No description available._ - -**Constructor:** _Class has no constructor._ - - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_model_classification.md b/docs/Stdlib/API/simpleml_model_classification.md deleted file mode 100644 index ef424e5b5..000000000 --- a/docs/Stdlib/API/simpleml_model_classification.md +++ /dev/null @@ -1,169 +0,0 @@ -# Package `simpleml.model.classification` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`DecisionTreeClassifier`](#class-DecisionTreeClassifier) - * [`DecisionTreeClassifierModel`](#class-DecisionTreeClassifierModel) - * [`RandomForestClassifier`](#class-RandomForestClassifier) - * [`RandomForestClassifierModel`](#class-RandomForestClassifierModel) - * [`SupportVectorMachineClassifier`](#class-SupportVectorMachineClassifier) - * [`SupportVectorMachineClassifierModel`](#class-SupportVectorMachineClassifierModel) - ----------- - - - -## Class `DecisionTreeClassifier` -_No description available._ - -**Constructor parameters:** -* `maxDepth: Int? = null` - _No description available._ - -**Attributes:** -* `attr maxDepth: Int?` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: DecisionTreeClassifierModel` - _No description available._ - - ----------- - - - -## Class `DecisionTreeClassifierModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - - - -## Class `RandomForestClassifier` -_No description available._ - -**Constructor parameters:** -* `nEstimator: Int = 100` - _No description available._ -* `criterion: String = "gini"` - _No description available._ -* `maxDepth: Int? = null` - _No description available._ -* `randomState: Int? = null` - _No description available._ - -**Attributes:** -* `attr criterion: String` - _No description available._ -* `attr maxDepth: Int?` - _No description available._ -* `attr nEstimator: Int` - _No description available._ -* `attr randomState: Int?` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RandomForestClassifierModel` - _No description available._ - - ----------- - - - -## Class `RandomForestClassifierModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - - - -## Class `SupportVectorMachineClassifier` -_No description available._ - -**Constructor parameters:** -* `penalty: String = "l2"` - _No description available._ -* `loss: String = "squared_hinge"` - _No description available._ -* `dual: Boolean = true` - _No description available._ -* `tol: Float = 1e-4` - _No description available._ -* `c: Float = 1.0` - _No description available._ -* `multiClass: String = "ovr"` - _No description available._ - -**Attributes:** -* `attr c: Float` - _No description available._ -* `attr dual: Boolean` - _No description available._ -* `attr loss: String` - _No description available._ -* `attr multiClass: String` - _No description available._ -* `attr penalty: String` - _No description available._ -* `attr tol: Float` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: SupportVectorMachineClassifierModel` - _No description available._ - - ----------- - - - -## Class `SupportVectorMachineClassifierModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_model_regression.md b/docs/Stdlib/API/simpleml_model_regression.md deleted file mode 100644 index c1de0fc68..000000000 --- a/docs/Stdlib/API/simpleml_model_regression.md +++ /dev/null @@ -1,200 +0,0 @@ -# Package `simpleml.model.regression` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`DecisionTreeRegressor`](#class-DecisionTreeRegressor) - * [`DecisionTreeRegressorModel`](#class-DecisionTreeRegressorModel) - * [`LinearRegression`](#class-LinearRegression) - * [`LinearRegressionModel`](#class-LinearRegressionModel) - * [`RandomForestRegressor`](#class-RandomForestRegressor) - * [`RandomForestRegressorModel`](#class-RandomForestRegressorModel) - * [`RidgeRegression`](#class-RidgeRegression) - * [`RidgeRegressionModel`](#class-RidgeRegressionModel) - ----------- - - - -## Class `DecisionTreeRegressor` -_No description available._ - -**Constructor parameters:** -* `maxDepth: Int? = null` - _No description available._ - -**Attributes:** -* `attr maxDepth: Int?` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: DecisionTreeRegressorModel` - _No description available._ - - ----------- - - - -## Class `DecisionTreeRegressorModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - - - -## Class `LinearRegression` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: LinearRegressionModel` - _No description available._ - - ----------- - - - -## Class `LinearRegressionModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - - - -## Class `RandomForestRegressor` -_No description available._ - -**Constructor parameters:** -* `nEstimator: Int = 100` - _No description available._ -* `criterion: String = "mse"` - _No description available._ -* `maxDepth: Int? = null` - _No description available._ -* `randomState: Int? = null` - _No description available._ - -**Attributes:** -* `attr criterion: String?` - _No description available._ -* `attr maxDepth: Int?` - _No description available._ -* `attr nEstimator: Int?` - _No description available._ -* `attr randomState: Int?` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RandomForestRegressorModel` - _No description available._ - - ----------- - - - -## Class `RandomForestRegressorModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - - - -## Class `RidgeRegression` -_No description available._ - -**Constructor parameters:** -* `regularizationStrength: Float = 0.5` - _No description available._ - -**Attributes:** -* `attr regularizationStrength: Float` - _No description available._ - -### `fit` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RidgeRegressionModel` - _No description available._ - - ----------- - - - -## Class `RidgeRegressionModel` -_No description available._ - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -_No description available._ - -**Parameters:** -* `features: Dataset` - _No description available._ - -**Results:** -* `results: Dataset` - _No description available._ - - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_model_supervised_classification.md b/docs/Stdlib/API/simpleml_model_supervised_classification.md deleted file mode 100644 index d4cf5e9e3..000000000 --- a/docs/Stdlib/API/simpleml_model_supervised_classification.md +++ /dev/null @@ -1,169 +0,0 @@ -# Package `simpleml.model.supervised.classification` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`DecisionTreeClassifier`](#class-DecisionTreeClassifier) - * [`DecisionTreeClassifierModel`](#class-DecisionTreeClassifierModel) - * [`RandomForestClassifier`](#class-RandomForestClassifier) - * [`RandomForestClassifierModel`](#class-RandomForestClassifierModel) - * [`SupportVectorMachineClassifier`](#class-SupportVectorMachineClassifier) - * [`SupportVectorMachineClassifierModel`](#class-SupportVectorMachineClassifierModel) - ----------- - - - -## Class `DecisionTreeClassifier` -Functionalities to train a decision tree classification model. - -**Constructor parameters:** -* `maxDepth: Int? = null` - _No description available._ - -**Attributes:** -* `attr maxDepth: Int?` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: DecisionTreeClassifierModel` - _No description available._ - - ----------- - - - -## Class `DecisionTreeClassifierModel` -A trained decision tree classification model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - - - -## Class `RandomForestClassifier` -Functionalities to train a random forest classification model. - -**Constructor parameters:** -* `nEstimator: Int = 100` - _No description available._ -* `criterion: String = "gini"` - _No description available._ -* `maxDepth: Int? = null` - _No description available._ -* `randomState: Int? = null` - _No description available._ - -**Attributes:** -* `attr criterion: String` - _No description available._ -* `attr maxDepth: Int?` - _No description available._ -* `attr nEstimator: Int` - _No description available._ -* `attr randomState: Int?` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RandomForestClassifierModel` - _No description available._ - - ----------- - - - -## Class `RandomForestClassifierModel` -A trained random forest classification model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - - - -## Class `SupportVectorMachineClassifier` -Functionalities to train an SVM classification model. - -**Constructor parameters:** -* `penalty: String = "l2"` - _No description available._ -* `loss: String = "squared_hinge"` - _No description available._ -* `dual: Boolean = true` - _No description available._ -* `tol: Float = 1e-4` - _No description available._ -* `c: Float = 1.0` - _No description available._ -* `multiClass: String = "ovr"` - _No description available._ - -**Attributes:** -* `attr c: Float` - _No description available._ -* `attr dual: Boolean` - _No description available._ -* `attr loss: String` - _No description available._ -* `attr multiClass: String` - _No description available._ -* `attr penalty: String` - _No description available._ -* `attr tol: Float` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: SupportVectorMachineClassifierModel` - _No description available._ - - ----------- - - - -## Class `SupportVectorMachineClassifierModel` -A trained SVM classification model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - -**This file was created automatically. Do not change it manually!** diff --git a/docs/Stdlib/API/simpleml_model_supervised_regression.md b/docs/Stdlib/API/simpleml_model_supervised_regression.md deleted file mode 100644 index d163b85ad..000000000 --- a/docs/Stdlib/API/simpleml_model_supervised_regression.md +++ /dev/null @@ -1,200 +0,0 @@ -# Package `simpleml.model.supervised.regression` - -[Tutorial][tutorial] - [Idea and basic concepts][tutorial_concepts] | [Interface][tutorial_interface] | [**API**][api] | [DSL][dsl-tutorial] - -[tutorial]: ../../Tutorial.md -[tutorial_concepts]: ../../Tutorial-Basic-Concepts.md -[tutorial_interface]: ../../Tutorial-The-Simple-ML-Interface.md -[api]: ./README.md -[dsl-tutorial]: ../../DSL/tutorial/README.md - - -## Table of Contents - -* Classes - * [`DecisionTreeRegressor`](#class-DecisionTreeRegressor) - * [`DecisionTreeRegressorModel`](#class-DecisionTreeRegressorModel) - * [`LinearRegression`](#class-LinearRegression) - * [`LinearRegressionModel`](#class-LinearRegressionModel) - * [`RandomForestRegressor`](#class-RandomForestRegressor) - * [`RandomForestRegressorModel`](#class-RandomForestRegressorModel) - * [`RidgeRegression`](#class-RidgeRegression) - * [`RidgeRegressionModel`](#class-RidgeRegressionModel) - ----------- - - - -## Class `DecisionTreeRegressor` -Functionalities to train a decision tree regression model. - -**Constructor parameters:** -* `maxDepth: Int? = null` - _No description available._ - -**Attributes:** -* `attr maxDepth: Int?` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for training the model. -* `target: Dataset` - A dataset consisting of one column with the target values. - -**Results:** -* `trainedModel: DecisionTreeRegressorModel` - A trained decision tree regression model. - - ----------- - - - -## Class `DecisionTreeRegressorModel` -A trained decision tree regression model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - - - -## Class `LinearRegression` -Functionalities to train a linear regression model. - -**Constructor parameters:** _None expected._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for training the model. -* `target: Dataset` - A dataset consisting of one column with the target values. - -**Results:** -* `trainedModel: LinearRegressionModel` - A trained linear regression model. - - ----------- - - - -## Class `LinearRegressionModel` -A trained linear regression model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - - - -## Class `RandomForestRegressor` -Functionalities to train a random forest regression model. - -**Constructor parameters:** -* `nEstimator: Int = 100` - _No description available._ -* `criterion: String = "mse"` - _No description available._ -* `maxDepth: Int? = null` - _No description available._ -* `randomState: Int? = null` - _No description available._ - -**Attributes:** -* `attr criterion: String?` - _No description available._ -* `attr maxDepth: Int?` - _No description available._ -* `attr nEstimator: Int?` - _No description available._ -* `attr randomState: Int?` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RandomForestRegressorModel` - _No description available._ - - ----------- - - - -## Class `RandomForestRegressorModel` -A trained random forest regression model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - - - -## Class `RidgeRegression` -Functionalities to train a ridge regression model. - -**Constructor parameters:** -* `regularizationStrength: Float = 0.5` - _No description available._ - -**Attributes:** -* `attr regularizationStrength: Float` - _No description available._ - -### `fit` (Instance Method ) -Train the model given a dataset of features and a dataset of labels - -**Parameters:** -* `features: Dataset` - _No description available._ -* `target: Dataset` - _No description available._ - -**Results:** -* `trainedModel: RidgeRegressionModel` - _No description available._ - - ----------- - - - -## Class `RidgeRegressionModel` -A trained ridge regression model. - -**Constructor parameters:** _None expected._ - -### `predict` (Instance Method ) -Predict values given a dataset of features - -**Parameters:** -* `features: Dataset` - A dataset consisting of features for prediction. - -**Results:** -* `results: Dataset` - A dataset consisting of the predicted values. - - ----------- - -**This file was created automatically. Do not change it manually!**