-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add flexplot * Add po files
- Loading branch information
Showing
21 changed files
with
2,343 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
flexplotInternal <- function(jaspResults, dataset, options) { | ||
return(flexplot:::flexplot_jasp2(jaspResults, dataset, options)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# | ||
# Copyright (C) 2013-2022 University of Amsterdam | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License as published by | ||
# the Free Software Foundation, either version 2 of the License, or | ||
# (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
|
||
# This is a generated file. Don't change it | ||
|
||
flexplot <- function( | ||
data = NULL, | ||
version = "0.18.3", | ||
formula = NULL, | ||
alpha = 0.4, | ||
bw = FALSE, | ||
confidence = FALSE, | ||
dependent = "", | ||
ghost = TRUE, | ||
intervals = "Quartiles", | ||
jitx = 0.1, | ||
jity = 0, | ||
nameCols = "", | ||
nameLegend = "", | ||
nameRows = "", | ||
nameX = "", | ||
nameY = "", | ||
palette = "GGplot Default", | ||
paneledVars = list(), | ||
plotHeight = 320, | ||
plotWidth = 480, | ||
theme = "JASP", | ||
type = "Loess", | ||
variables = list()) { | ||
|
||
defaultArgCalls <- formals(jaspDescriptives::flexplot) | ||
defaultArgs <- lapply(defaultArgCalls, eval) | ||
options <- as.list(match.call())[-1L] | ||
options <- lapply(options, eval) | ||
defaults <- setdiff(names(defaultArgs), names(options)) | ||
options[defaults] <- defaultArgs[defaults] | ||
options[["data"]] <- NULL | ||
options[["version"]] <- NULL | ||
|
||
if (!is.null(formula)) { | ||
if (!inherits(formula, "formula")) { | ||
formula <- as.formula(formula) | ||
} | ||
options$formula <- jaspBase::jaspFormula(formula, data) | ||
} | ||
|
||
optionsWithFormula <- c("dependent", "intervals", "palette", "paneledVars", "theme", "type", "variables") | ||
for (name in optionsWithFormula) { | ||
if ((name %in% optionsWithFormula) && inherits(options[[name]], "formula")) options[[name]] = jaspBase::jaspFormula(options[[name]], data) } | ||
|
||
return(jaspBase::runWrappedAnalysis("jaspDescriptives::flexplot", data, options, version)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import QtQuick | ||
import "common" as COMMON | ||
|
||
COMMON.FlexplotForm {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,210 @@ | ||
import QtQuick | ||
import JASP.Controls | ||
import JASP | ||
|
||
Form | ||
{ | ||
Formula | ||
{ | ||
lhs: "dependent" | ||
rhs: "variables" | ||
} | ||
|
||
VariablesForm | ||
{ | ||
AvailableVariablesList { name: "allVariables" } | ||
AssignedVariablesList { | ||
name: "dependent" ; | ||
title: qsTr("Dependent Variable") ; | ||
singleVariable: true | ||
onCountChanged: nameY.value = count > 0 ? model.data(model.index(0,0)) : "" | ||
} | ||
AssignedVariablesList { | ||
name: "variables" ; | ||
title: qsTr("Independent Variable(s)") ; | ||
id: varlist | ||
onCountChanged: { | ||
nameLegend.value = count > 1 ? model.data(model.index(1,0)) : ""; | ||
nameX.value = count > 0 ? model.data(model.index(0,0)) : ""; | ||
} | ||
|
||
} | ||
AssignedVariablesList { | ||
name: "paneledVars" ; | ||
title: qsTr("Paneled Variable(s)"); | ||
id: paneledVars | ||
onCountChanged: { | ||
nameCols.value = count > 0 ? model.data(model.index(0,0)) : ""; | ||
nameRows.value = count > 1 ? model.data(model.index(1,0)) : ""; | ||
} | ||
|
||
} | ||
} | ||
|
||
Section | ||
{ | ||
title: qsTr("Options") | ||
|
||
Group | ||
{ | ||
title: qsTr("<br><strong>Point controls</br></strong>") | ||
columns: 4 | ||
Slider | ||
{ | ||
name: "alpha" | ||
label: qsTr("Point transparency") | ||
value: 0.4 | ||
vertical: true | ||
enabled: varlist.count > 0 | ||
} | ||
Slider | ||
{ | ||
name: "jitx" | ||
label: qsTr("Jitter in X") | ||
value: .1 | ||
min: 0 | ||
max: .5 | ||
vertical: true | ||
enabled: varlist.count > 0 | ||
} | ||
Slider | ||
{ | ||
name: "jity" | ||
label: qsTr("Jitter in Y") | ||
value: 0 | ||
min: 0 | ||
max: .5 | ||
vertical: true | ||
enabled: varlist.count > 0 | ||
} | ||
} | ||
Group | ||
{ | ||
Group | ||
{ | ||
title: qsTr("<strong>Visual Statistics</strong>") | ||
CheckBox | ||
{ | ||
name:"confidence"; | ||
label: qsTr("Plot confidence bands") | ||
enabled: varlist.count > 0 | ||
} | ||
DropDown | ||
{ | ||
name: "type" | ||
values: | ||
[ | ||
{label: qsTr("Loess"), value: "Loess"}, | ||
{label: qsTr("Regression"), value: "Regression"}, | ||
{label: qsTr("Quadratic"), value: "Quadratic"}, | ||
{label: qsTr("Cubic"), value: "Cubic"}, | ||
{label: qsTr("None"), value: "None"} | ||
] | ||
label: qsTr("Fitted line (scatterplots)") | ||
enabled: varlist.count > 0 | ||
} | ||
DropDown | ||
{ | ||
name: "intervals" | ||
values: | ||
[ | ||
{label: qsTr("Quartiles"), value: "Quartiles"}, | ||
{label: qsTr("Standard errors"), value: "Standard errors"}, | ||
{label: qsTr("Standard deviations"), value: "Standard deviations"} | ||
] | ||
label: qsTr("Intervals (categorical predictors)") | ||
enabled: varlist.count > 0 | ||
} | ||
} | ||
|
||
Group | ||
{ | ||
title: qsTr("<br><strong>Other Plot Controls</strong>") | ||
DropDown | ||
{ | ||
name: "theme" | ||
values: | ||
[ | ||
{label: qsTr("JASP"), value: "JASP"}, | ||
{label: qsTr("Black and white"), value: "Black and white"}, | ||
{label: qsTr("Minimal"), value: "Minimal"}, | ||
{label: qsTr("Classic"), value: "Classic"}, | ||
{label: qsTr("Dark"), value: "Dark"} | ||
] | ||
label: qsTr("GGplot theme") | ||
} | ||
DropDown | ||
{ | ||
name: "palette" | ||
values: | ||
[ | ||
{label: qsTr("GGplot Default"), value: "GGplot Default"}, | ||
{label: qsTr("Nature"), value: "Nature"}, | ||
{label: qsTr("AAAS"), value: "AAAS"}, | ||
{label: qsTr("Lancet"), value: "Lancet"}, | ||
{label: qsTr("JCO"), value: "JCO"}, | ||
{label: qsTr("Dark"), value: "Dark"} | ||
] | ||
label: qsTr("Color Palette") | ||
} | ||
CheckBox | ||
{ | ||
name:"bw"; | ||
label: qsTr("Convert to grayscale"); | ||
checked: false | ||
} | ||
|
||
CheckBox | ||
{ | ||
name:"ghost"; | ||
label: qsTr("Ghost lines"); | ||
checked: true | ||
enabled: paneledVars.count > 0 | ||
} | ||
} | ||
} | ||
} | ||
|
||
Section | ||
{ | ||
title: qsTr("Plot Labels") | ||
Group | ||
{ | ||
title: qsTr("<br><strong>Plot Labels</strong>") | ||
TextField | ||
{ | ||
id: nameX; | ||
label: qsTr("X Axis Label"); | ||
name: "nameX"; | ||
} | ||
TextField | ||
{ | ||
id: nameY | ||
label: qsTr("Y Axis Label") | ||
name: "nameY"; | ||
value: xAxis.value | ||
} | ||
TextField | ||
{ | ||
id: nameLegend | ||
label: qsTr("Legend Label") | ||
name: "nameLegend"; | ||
value: legend.value | ||
} | ||
TextField | ||
{ | ||
id: nameCols | ||
label: qsTr("Column Panel Label") | ||
name: "nameCols"; | ||
value: cols.value | ||
} | ||
TextField | ||
{ | ||
id: nameRows | ||
label: qsTr("Row Panel Label") | ||
name: "nameRows"; | ||
value: rows.value | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
module <jaspDescriptives> | ||
DescriptivesTimeSeriesForm 1.0 qml/common/DescriptivesTimeSeriesForm.qml | ||
FlexplotForm 1.0 qml/common/FlexplotForm.qml |
Oops, something went wrong.