Skip to content

Commit

Permalink
Initial GitHub commit version 1.4.5
Browse files Browse the repository at this point in the history
  • Loading branch information
PavelBal committed Apr 13, 2021
1 parent 4685767 commit 506efd4
Show file tree
Hide file tree
Showing 167 changed files with 79,673 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
^.*\.Rproj$
^\.Rproj\.user$
^doc$
^Meta$
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.Rproj.user
.Rhistory
.RData
.Ruserdata
doc
Meta
55 changes: 55 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
Package: esqlabsR
Type: Package
Title: esqLABS utilities package
Version: 1.4.5
Author: esqLABS GmbH
Maintainer: Pavel Balazki <[email protected]>
Description: Utilities functions for modeling and simulation projects within esqLABS.
Encoding: UTF-8
LazyData: true
Depends:
ospsuite (>= 10.0)
Imports:
tools,
openxlsx,
parallel,
shiny,
shinyjs
Suggests:
knitr,
rmarkdown,
testthat (>= 2.1.0),
pander
VignetteBuilder: knitr
License:
Proprietary
RoxygenNote: 7.1.1
Collate:
'DataConfiguration.R'
'DataMapping.R'
'DataMappingConfiguration.R'
'OSPSTimeValues.R'
'PlotConfiguration.R'
'Plotable.R'
'Printable.R'
'enum.R'
'XYData.R'
'error-checks.R'
'esqlabs-env.R'
'map.R'
'messages.R'
'shiny-app-launcher.R'
'utilities-data-mapping.R'
'utilities-data.R'
'utilities-dimensions.R'
'utilities-figures.R'
'utilities-file.R'
'utilities-individual.R'
'utilities-parallel.R'
'utilities-parameters.R'
'utilities-population.R'
'utilities-simulation.R'
'utilities-steady-state.R'
'utilities-transfer-functions.R'
'utilities.R'
'zzz.R'
83 changes: 83 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# Generated by roxygen2: do not edit by hand

export("%||%")
export(DataConfiguration)
export(DataMapping)
export(DataMappingConfiguration)
export(Dimensions)
export(Distributions)
export(GenderInt)
export(GraphicsDevices)
export(OSPSTimeValues)
export(PlotConfiguration)
export(PlotTypes)
export(Printable)
export(XYData)
export(XYDataTypes)
export(applyIndividualParameters)
export(calculateRMSE)
export(col2hsv)
export(compareSimulationParameters)
export(compareWithNA)
export(dimensionsConversionFactor)
export(enumGetKey)
export(enumPutList)
export(esqLABS_colors)
export(executeInParallel)
export(existsDimension)
export(exportSteadyStateToXLS)
export(extendPopulationByUserDefinedParams)
export(extendPopulationFromXLS)
export(foldChangeFunction)
export(geomean)
export(geosd)
export(getAllStateVariables)
export(getBaseUnit)
export(getEsqlabsRSetting)
export(getIndexClosestToValue)
export(getQuantilesYData)
export(getSteadyState)
export(getUnitConversionFactor)
export(hasUnit)
export(hillFunction)
export(initializeSimulation)
export(isCharInString)
export(isParametersEqual)
export(isTableFormulasEqual)
export(map)
export(mapGetKey)
export(mapGetValue)
export(mapHasKey)
export(mapKeys)
export(mapPut)
export(mapPutList)
export(mapRemove)
export(mapValues)
export(pathFromClipboard)
export(plotBoxPlot)
export(plotMultiPanel)
export(plotPredictedVsObserved)
export(plotXYDataAggregated)
export(readOSPSTimeValues)
export(readParametersFromXLS)
export(readPopulationCharacteristicsFromXLS)
export(removeFromList)
export(sampleRandomValue)
export(setParameterValuesByPathWithCondition)
export(setParameterValuesByPathWithUnit)
export(sineFunction)
export(sourceAll)
export(startFunctionVisualizer)
export(stringToNum)
export(validateDimension)
export(validateFileExists)
export(validateIsInteger)
export(validateIsLogical)
export(validateIsNumeric)
export(validateIsSameLength)
export(validateIsString)
export(validateLength)
export(validateUnit)
export(writeIndividualToXLS)
import(openxlsx)
import(parallel)
64 changes: 64 additions & 0 deletions R/DataConfiguration.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
#' @title DataConfiguration
#' @docType class
#' @description An object storing configuration of for observed data import
#' @export
#' @format NULL
DataConfiguration <- R6::R6Class(
"DataConfiguration",
inherit = Printable,
cloneable = FALSE,
active = list(),
private = list(),
public = list(
#' @param dataFolder Path to the directory where the data file is located
#' @param dataFile Name of the data excel file
#' @param dataSheets Name of excel sheets to read
#' @param compoundPropertiesFile Name of the excel file with compound properties
#' @description
#' Initialize a new instance of the class
#' @return A new `DataConfiguration` object.
initialize = function(dataFolder, dataFile, compoundPropertiesFile, dataSheets) {
self$dataFolder <- dataFolder
self$dataFile <- dataFile
self$compoundPropertiesFile <- compoundPropertiesFile
self$dataSheets <- dataSheets
self$columnsToSplitBy <- esqlabsEnv$columnsToSplitDataBy
self$XValuesColumn <- esqlabsEnv$XValuesColumn
self$YValuesColumn <- esqlabsEnv$YValuesColumn
self$YErrorColumn <- esqlabsEnv$YErrorColumn
},

#' @field dataFolder Path to the directory where the data file is located
dataFolder = "",
#' @field dataFile Name of the data excel file
dataFile = "",
#' @field compoundPropertiesFile Name of the excel file with compound properties
compoundPropertiesFile = "Compound Properties.xlsx",
#' @field dataSheets Name of excel sheets to read
dataSheets = c(),
#' @field columnsToSplitBy Column names by which the data will be split into groups
columnsToSplitBy = "",
#' @field XValuesColumn Column index for x values in observed data files
XValuesColumn = 0,
#' @field YValuesColumn Column index for y values in observed data files
YValuesColumn = 0,
#' @field YErrorColumn Column index for y error values in observed data files
YErrorColumn = 0,

#' @description
#' Print the object to the console
#' @param ... Rest arguments.
print = function(...) {
private$printClass()
private$printLine("Data file directory", self$dataFolder)
private$printLine("Data file", self$dataFile)
private$printLine("Sheets", self$dataSheets)
private$printLine("CompoundProperties file", self$compoundPropertiesFile)
private$printLine("Columns to split by", self$columnsToSplitBy)
private$printLine("X values column", self$XValuesColumn)
private$printLine("Y values column", self$YValuesColumn)
private$printLine("Y error column", self$YErrorColumn)
invisible(self)
}
)
)
Loading

0 comments on commit 506efd4

Please sign in to comment.