Package 'AutoPlots'

Title: Creating Echarts Visualizations as Easy as Possible
Description: Create beautiful and interactive visualizations in a single function call. The 'data.table' package is utilized to perform the data wrangling necessary to prepare your data for the plot types you wish to build, along with allowing fast processing for big data. There are two broad classes of plots available: standard plots and machine learning evaluation plots. There are lots of parameters available in each plot type function for customizing the plots (such as faceting) and data wrangling (such as variable transformations and aggregation).
Authors: Adrian Antico [aut, cre, cph]
Maintainer: Adrian Antico <[email protected]>
License: AGPL (>= 3)
Version: 1.0.0
Built: 2025-02-21 04:30:12 UTC
Source: https://github.com/adrianantico/autoplots

Help Index


FakeDataGenerator

Description

Create fake data for examples

Usage

FakeDataGenerator(
  Correlation = 0.7,
  N = 1000L,
  ID = 5L,
  FactorCount = 2L,
  AddDate = TRUE,
  AddComment = FALSE,
  AddWeightsColumn = FALSE,
  ZIP = 5L,
  ChainLadderData = FALSE,
  Classification = FALSE,
  MultiClass = FALSE
)

Arguments

Correlation

Set the correlation value for simulated data

N

Number of records

ID

Number of IDcols to include

FactorCount

Number of factor type columns to create

AddDate

Set to TRUE to include a date column

AddComment

Set to TRUE to add a comment column

AddWeightsColumn

Add a weights column for ML

ZIP

Zero Inflation Model target variable creation. Select from 0 to 5 to create that number of distinctly distributed data, stratifed from small to large

ChainLadderData

Set to TRUE to return Chain Ladder Data for using AutoMLChainLadderTrainer

Classification

Set to TRUE to build classification data

MultiClass

Set to TRUE to build MultiClass data

Value

data.table of data

Author(s)

Adrian Antico


Plot.ACF

Description

Build an autocorrelation plot by simply passing arguments to a single function

Usage

Plot.ACF(
  dt = NULL,
  YVar = NULL,
  DateVar = NULL,
  TimeUnit = NULL,
  MaxLags = 50,
  YVarTrans = "Identity",
  AggMethod = "sum",
  Height = NULL,
  Width = NULL,
  Title = "Autocorrelation Plot",
  EchartsTheme = "macarons",
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

YVar

Y-Axis variable name

DateVar

Date column in data

TimeUnit

Select from "hour", "day", "week", "month", "quarter", "year"

MaxLags

Max lag values to test

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()


Plot.Area

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.Area(
  dt = NULL,
  AggMethod = "mean",
  PreAgg = TRUE,
  XVar = NULL,
  YVar = NULL,
  DualYVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  DualYVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Line Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  Alpha = 0.5,
  Smooth = TRUE,
  ShowSymbol = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name. You can supply multiple YVars

DualYVar

Secondary Y-Axis variables. Leave NULL for no secondary axis. Only one variable is allowed and when this is set only one YVar is allowed. An error will be thrown if those conditions are not met

GroupVar

One Grouping Variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

DualYVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

"Title"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

Provide an "Echarts" theme

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

Alpha

0 to 1 for setting transparency

Smooth

= TRUE

ShowSymbol

= FALSE

TextColor

"Not Implemented"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Area

logical

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 1000)

# Build plot
AutoPlots::Plot.Area(
  dt = data,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = "DateTime",
  YVar = "Independent_Variable3",
  YVarTrans = "Identity",
  DualYVar = "Independent_Variable6",
  DualYVarTrans = "Identity",
  GroupVar = NULL,
  EchartsTheme = "macarons")

Plot.Bar

Description

Build a bar plot by simply passing arguments to a single function

Usage

Plot.Bar(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  LabelValues = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Bar Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

LabelValues

A vector of values. Requires PreAgg to be set to TRUE and you'll need to ensure LabelValues are ordered the same as dt. If NULL and ShowLabels is TRUE, then bar values will be displayed

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

ShowLabels

logical

Title.YAxis

NULL. If NULL, YVar name will be used

Title.XAxis

NULL. If NULL, XVar name will be used

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts Bar Chart
AutoPlots::Plot.Bar(
  dt = data,
  PreAgg = FALSE,
  XVar = "Factor_1",
  YVar = "Adrian",
  GroupVar = NULL,
  LabelValues = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = 'mean',
  Height = NULL,
  Width = NULL,
  Title = 'Bar Plot',
  ShowLabels = FALSE,
  Title.YAxis = "Adrian",
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.BarPlot3D

Description

Build a 3D Bar Plot

Usage

Plot.BarPlot3D(
  dt,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_Y = 33,
  NumLevels_X = 33,
  Height = NULL,
  Width = NULL,
  Title = "3D Bar Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "dark",
  MouseScroll = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical. Is your data pre aggregated

AggMethod

'mean', 'median', 'sum', 'sd', 'coeffvar', 'count'

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

Z-Axis variable name

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

= 21

NumLevels_Y

= 20

NumLevels_X

= 20

Height

"400px"

Width

"200px"

Title

"Heatmap"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"dark-blue"

MouseScroll

logical, zoom via mouse scroll

TextColor

character

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

zaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts 3D Bar Chart
AutoPlots::Plot.BarPlot3D(
  dt = data,
  PreAgg = FALSE,
  AggMethod = 'mean',
  XVar = "Factor_1",
  YVar = "Factor_2",
  ZVar = "Adrian",
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_Y = 33,
  NumLevels_X = 33,
  Height = NULL,
  Width = NULL,
  Title = "3D Bar Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.BinaryMetrics

Description

Line plot of evaluation metrics across thresholds

Usage

Plot.BinaryMetrics(
  dt = NULL,
  PreAgg = FALSE,
  AggMethod = "mean",
  SampleSize = 100000L,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  Metrics = c("Utility", "MCC", "Accuracy", "F1_Score", "F2_Score", "F0.5_Score",
    "ThreatScore", "TPR", "TNR", "FNR", "FPR", "FDR", "FOR"),
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  CostMatrixWeights = c(0, 1, 1, 0),
  NumberBins = 20,
  Height = NULL,
  Width = NULL,
  Title = "Binary Metrics",
  MouseScroll = TRUE,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  EchartsLabels = FALSE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

AggMethod

character

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

Metrics

Multiple selection "Utility","MCC","Accuracy","F1_Score","F2_Score","F0.5_Score","ThreatScore","TPR","TNR","FNR","FPR","FDR","FOR"

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

CostMatrixWeights

vector length 4. FP, FP, FN, TP

NumberBins

numeric

Height

"400px"

Width

"200px"

Title

character

MouseScroll

logical, zoom via mouse scroll

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

EchartsLabels

character

TimeLine

logical

TextColor

hex character

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Box

Description

Build a box plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Box(
  dt = NULL,
  SampleSize = 100000L,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Box Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

TextColor

character hex

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)), GV = sample(LETTERS, 1000, TRUE))

AutoPlots::Plot.Box(
  dt = dt,
  SampleSize = 100000L,
  XVar = "GV",
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = 'Box Plot',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.Calibration.Box

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.Calibration.Box(
  dt = NULL,
  SampleSize = 100000L,
  AggMethod = "mean",
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  Height = NULL,
  Width = NULL,
  Title = "Calibration Box",
  MouseScroll = TRUE,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

numeric

AggMethod

character

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

Height

"400px"

Width

"200px"

Title

character

MouseScroll

logical, zoom via mouse scroll

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

"Not Implemented"

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Calibration.Line

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.Calibration.Line(
  dt = NULL,
  AggMethod = "mean",
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  Height = NULL,
  Width = NULL,
  Title = "Calibration Line",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  MouseScroll = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

MouseScroll

logical, zoom via mouse scroll

TextColor

"Not Implemented"

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.ConfusionMatrix

Description

Generate variable importance plots

Usage

Plot.ConfusionMatrix(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  ZVar = "N",
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_X = 50,
  NumLevels_Y = 50,
  Height = NULL,
  Width = NULL,
  Title = "Confusion Matrix",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "white",
  AggMethod = "count",
  GroupVar = NULL,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

FALSE

XVar

Column name of X-Axis variable. If NULL then ignored

YVar

Column name of Y-Axis variable. If NULL then ignored

ZVar

= "N"

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

= 21,

NumLevels_X

= NumLevels_Y,

NumLevels_Y

= NumLevels_X,

Height

"400px"

Width

"200px"

Title

title

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

'darkblue'

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

GroupVar

= NULL

xaxis.rotate

numeric

yaxis.rotate

numeric

ContainLabel

logical

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Copula

Description

Build a copula plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Copula(
  dt = NULL,
  SampleSize = 30000L,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Copula Plot",
  ShowLabels = FALSE,
  AddGLM = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "white",
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

An integer for the number of rows to use. Sampled data is randomized. If NULL then ignored

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Requires an XVar and YVar already be defined

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

'Copula Plot'

ShowLabels

character

AddGLM

logical

Title.YAxis

character

Title.XAxis

character

EchartsTheme

= "dark-blue",

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

TextColor

'darkblue'

yaxis.fontSize

14

xaxis.fontSize

14

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts Copula Plot Chart
AutoPlots::Plot.Copula(
  dt = data,
  SampleSize = 10000,
  XVar = "Independent_Variable8",
  YVar = "Adrian",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = 'Copula Plot',
  ShowLabels = FALSE,
  AddGLM = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "black",
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.Copula3D

Description

Build a 3D-copula plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Copula3D(
  dt = NULL,
  SampleSize = 1e+05,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  GroupVar = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Copula 3D",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "dark-blue",
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  zaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

An integer for the number of rows to use. Sampled data is randomized. If NULL then ignored

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

Z-Axis variable name

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

GroupVar

Requires an XVar and YVar already be defined

Height

"400px"

Width

"200px"

Title

'Copula3D Plot'

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

= "dark-blue"

TimeLine

Logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

zaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

zaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)
data[, Independent_Variable9 := Independent_Variable9 * runif(.N)]

# Echarts Copula Plot Chart
AutoPlots::Plot.Copula3D(
  dt = data,
  SampleSize = 10000,
  XVar = "Adrian",
  YVar = "Independent_Variable9",
  ZVar = "Independent_Variable6",
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  GroupVar = NULL,
  Height = NULL,
  Width = NULL,
  Title = 'Copula 3D',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  zaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.CorrMatrix

Description

Build a correlation matrix plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.CorrMatrix(
  dt = NULL,
  CorrVars = NULL,
  CorrVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Method = "spearman",
  PreAgg = FALSE,
  MaxNAPercent = 0.05,
  Height = NULL,
  Width = NULL,
  Title = "Correlation Matrix",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

CorrVars

vector of variable names

CorrVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Method

character

PreAgg

logical

MaxNAPercent

numeric

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TextColor

character hex

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts CorrMatrix Plot Chart
AutoPlots::Plot.CorrMatrix(
  dt = data,
  CorrVars = c(
    "Adrian",
    "Independent_Variable1",
    "Independent_Variable2",
    "Independent_Variable3",
    "Independent_Variable4",
    "Independent_Variable5"),
  CorrVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Method = 'pearson',
  PreAgg = FALSE,
  MaxNAPercent = 0.05,
  Height = NULL,
  Width = NULL,
  Title = "Correlation Matrix",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  Debug = FALSE)

Plot.Density

Description

Density plots, by groups, with transparent continuous plots

Usage

Plot.Density(
  dt = NULL,
  SampleSize = 100000L,
  YVar = NULL,
  XVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  MouseScroll = TRUE,
  Title = "Density Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

= 100000L

YVar

Y-Axis variable name

XVar

X-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

MouseScroll

logical, zoom via mouse scroll

Title

= "Density Plot"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

"white"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)))

# Create plot
AutoPlots::Plot.Density(
  dt = dt,
  SampleSize = 30000L,
  XVar = NULL,
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  EchartsTheme = "macarons",
  Title = "Histogram",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE)

Plot.Donut

Description

Build a donut plot by simply passing arguments to a single function

Usage

Plot.Donut(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Donut Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo","essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired","jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal","sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

'darkblue'

title.fontSize

Defaults to size 22. Numeric. This changes the size of the title.

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)), GV = sample(LETTERS, 1000, TRUE))

# Create plot
AutoPlots::Plot.Donut(
  dt = dt,
  PreAgg = FALSE,
  XVar = "GV",
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = 'mean',
  Height = NULL,
  Width = NULL,
  Title = 'Pie Chart',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE)

Plot.Gains

Description

Create a cumulative gains chart

Usage

Plot.Gains(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  ZVar = "N",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 20,
  Height = NULL,
  Width = NULL,
  Title = "Gains Plot",
  ShowLabels = FALSE,
  Title.YAxis = "Gain",
  Title.XAxis = "Population",
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

Height

NULL

Width

NULL

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

character hex

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.HeatMap

Description

Create heat maps with numeric or categorical dt

Usage

Plot.HeatMap(
  dt,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_Y = 33,
  NumLevels_X = 33,
  Height = NULL,
  Width = NULL,
  Title = "Heatmap",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "dark",
  MouseScroll = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

AggMethod

'mean', 'median', 'sum', 'sd', 'coeffvar', 'count'

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

Z-Axis variable name

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

= 21

NumLevels_Y

= 20

NumLevels_X

= 20.

Height

"400px"

Width

"200px"

Title

"Heatmap"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"dark-blue"

MouseScroll

logical, zoom via mouse scroll

TextColor

color

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging parameter

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts Heatmap Plot Chart
AutoPlots::Plot.HeatMap(
  dt = data,
  PreAgg = FALSE,
  XVar = "Factor_1",
  YVar = "Factor_2",
  ZVar = "Independent_Variable6",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_Y = 33,
  NumLevels_X = 33,
  Height = NULL,
  Width = NULL,
  Title = "Heatmap",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.Histogram

Description

Build a histogram plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Histogram(
  dt = NULL,
  SampleSize = 30000L,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 30,
  Height = NULL,
  Width = NULL,
  EchartsTheme = "macarons",
  Title = "Histogram",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

An integer for the number of rows to use. Sampled data is randomized. If NULL then ignored

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

= 30

Height

"400px"

Width

"200px"

EchartsTheme

= EchartsTheme,

Title

character

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

ShowLabels

FALSE

Title.YAxis

NULL

Title.XAxis

NULL

TextColor

"white"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)))

# Create plot
AutoPlots::Plot.Histogram(
  dt = dt,
  SampleSize = 30000L,
  XVar = NULL,
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 30,
  Height = NULL,
  Width = NULL,
  EchartsTheme = "macarons",
  Title = "Histogram",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE)

Plot.Lift

Description

Create a cumulative gains chart

Usage

Plot.Lift(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  ZVar = "N",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 20,
  Height = NULL,
  Width = NULL,
  Title = "Confusion Matrix",
  ShowLabels = FALSE,
  Title.YAxis = "Lift",
  Title.XAxis = "Population",
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

character hex

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Line

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.Line(
  dt = NULL,
  AggMethod = "mean",
  PreAgg = TRUE,
  XVar = NULL,
  YVar = NULL,
  DualYVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  DualYVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Line Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  Area = FALSE,
  Alpha = 0.5,
  Smooth = TRUE,
  ShowSymbol = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  DarkMode = FALSE,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name. You can supply multiple YVars

DualYVar

Secondary Y-Axis variables. Leave NULL for no secondary axis. Only one variable is allowed and when this is set only one YVar is allowed. An error will be thrown if those conditions are not met

GroupVar

One Grouping Variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

DualYVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

NULL

Width

NULL

Title

"Title"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

Provide an "Echarts" theme

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

Area

logical

Alpha

0 to 1 for setting transparency

Smooth

= TRUE

ShowSymbol

= FALSE

TextColor

"Not Implemented"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

DarkMode

FALSE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 1000)

# Build Line plot
AutoPlots::Plot.Line(
  dt = data,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = "DateTime",
  YVar = "Independent_Variable3",
  YVarTrans = "LogPlus1",
  DualYVar = "Independent_Variable6",
  DualYVarTrans = "LogPlus1",
  GroupVar = NULL,
  EchartsTheme = "macarons")

Plot.PACF

Description

Build a partial autocorrelation plot by simply passing arguments to a single function

Usage

Plot.PACF(
  dt = NULL,
  YVar = NULL,
  DateVar = NULL,
  TimeUnit = NULL,
  MaxLags = 50,
  YVarTrans = "Identity",
  AggMethod = "sum",
  Height = NULL,
  Width = NULL,
  Title = "Partial Autocorrelation Plot",
  EchartsTheme = "macarons",
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

YVar

Y-Axis variable name

DateVar

Date column in data

TimeUnit

Select from "hour", "day", "week", "month", "quarter", "year"

MaxLags

Max value for lags to test

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()


Plot.Parallel

Description

Build a parallel plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Parallel(
  dt = NULL,
  SampleSize = 50000,
  CorrVars = NULL,
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  PreAgg = FALSE,
  Height = NULL,
  Width = NULL,
  Title = "Parallel Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

Sample size

CorrVars

vector of variable names

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

PreAgg

logical

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TextColor

character hex

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create data
dt = AutoPlots::FakeDataGenerator(N = 100000)

# Create plot
AutoPlots::Plot.Parallel(
  dt = dt,
  SampleSize = 1000,
  CorrVars = c("Independent_Variable3",
               "Independent_Variable4",
               "Independent_Variable5",
               "Independent_Variable6",
               "Independent_Variable7"),
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  PreAgg = FALSE,
  Height = NULL,
  Width = NULL,
  Title = "Parallel Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  Debug = FALSE)

Plot.PartialDependence.Box

Description

This function automatically builds partial dependence calibration plots

Usage

Plot.PartialDependence.Box(
  dt = NULL,
  PreAgg = FALSE,
  SampleSize = 100000L,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 20,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Partial Dependence Box",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  EchartsLabels = FALSE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

AggMethod

character

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

EchartsLabels

character

TimeLine

logical

TextColor

hex character

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.PartialDependence.HeatMap

Description

This function automatically builds partial dependence calibration plots

Usage

Plot.PartialDependence.HeatMap(
  dt = NULL,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Partial Dependence Heatmap",
  ShowLabels = FALSE,
  MouseScroll = TRUE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  EchartsLabels = FALSE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

AggMethod

character

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

MouseScroll

logical, zoom via mouse scroll

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

EchartsLabels

character

TimeLine

logical

TextColor

hex character

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.PartialDependence.Line

Description

This function automatically builds partial dependence calibration plots

Usage

Plot.PartialDependence.Line(
  dt = NULL,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  GroupVar = NULL,
  NumberBins = 20,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Partial Dependence Line",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  EchartsLabels = FALSE,
  TimeLine = TRUE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

character

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

GroupVar

Character variable

NumberBins

numeric

AggMethod

character

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

EchartsLabels

character

TimeLine

logical

TextColor

hex character

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Pie

Description

Build a pie chart by simply passing arguments to a single function

Usage

Plot.Pie(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Pie Chart",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo","essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired","jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal","sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)), GV = sample(LETTERS, 1000, TRUE))

# Create plot
AutoPlots::Plot.Pie(
  dt = dt,
  PreAgg = FALSE,
  XVar = "GV",
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = 'mean',
  Height = NULL,
  Width = NULL,
  Title = 'Pie Chart',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE)

Plot.ProbabilityPlot

Description

Build a normal probability plot

Usage

Plot.ProbabilityPlot(
  dt = NULL,
  SampleSize = 1000L,
  YVar = NULL,
  YVarTrans = "Identity",
  Height = NULL,
  Width = NULL,
  Title = "Normal Probability Plot",
  ShowLabels = FALSE,
  EchartsTheme = "macarons",
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  tooltip.trigger = "axis",
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

An integer for the number of rows to use. Sampled data is randomized. If NULL then ignored

YVar

Y-Axis variable name

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

Height

"400px"

Width

"200px"

Title

'Violin Plot'

ShowLabels

character

EchartsTheme

"macaron"

TextColor

'darkblue'

title.fontSize

Default 22

title.fontWeight

Default "bold"

title.textShadowColor

Default '#63aeff'

title.textShadowBlur

Default 3

title.textShadowOffsetY

Default 1

title.textShadowOffsetX

Default -1

yaxis.fontSize

Default 14

yaxis.rotate

Default 0

ContainLabel

Default TRUE

tooltip.trigger

Default "axis"

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)))

# Create plot
AutoPlots::Plot.ProbabilityPlot(
  dt = dt,
  SampleSize = 1000L,
  YVar = "Y",
  YVarTrans = "Identity",
  Height = NULL,
  Width = NULL,
  Title = 'Normal Probability Plot',
  ShowLabels = FALSE,
  EchartsTheme = "blue",
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  tooltip.trigger = "axis",
  Debug = FALSE)

Plot.Radar

Description

Plot.Radar

Usage

Plot.Radar(
  dt = NULL,
  AggMethod = "mean",
  PreAgg = TRUE,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  Height = NULL,
  Width = NULL,
  Title = "Radar Plot",
  ShowLabels = FALSE,
  EchartsTheme = "macarons",
  ShowSymbol = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  ContainLabel = TRUE,
  DarkMode = FALSE,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

PreAgg

logical

YVar

Y-Axis variable name. You can supply multiple YVars

GroupVar

One Grouping Variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

Height

"400px"

Width

"200px"

Title

"Title"

ShowLabels

character

EchartsTheme

Provide an "Echarts" theme

ShowSymbol

= FALSE

TextColor

"Not Implemented"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

ContainLabel

TRUE

DarkMode

FALSE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create Data
dt <- data.table::data.table(Y = pnorm(q = runif(8)), GV = sample(LETTERS[1:4], 8, TRUE))

# Create plot
AutoPlots::Plot.Radar(
  dt = dt,
  AggMethod = "mean",
  PreAgg = FALSE,
  YVar = "Y",
  GroupVar = "GV",
  YVarTrans = "Identity",
  Height = NULL,
  Width = NULL,
  Title = 'Radar Plot',
  ShowLabels = FALSE,
  EchartsTheme = "macarons",
  ShowSymbol = FALSE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  ContainLabel = TRUE,
  DarkMode = FALSE,
  Debug = FALSE)

Plot.Residuals.Histogram

Description

Residuals Plot

Usage

Plot.Residuals.Histogram(
  dt = NULL,
  AggMethod = "mean",
  SampleSize = 1e+05,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 20,
  Height = NULL,
  Width = NULL,
  Title = "Residuals Histogram",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = "Target - Predicted",
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

numeric

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

Not Implemented

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Residuals.Scatter

Description

Residuals_2 Plot

Usage

Plot.Residuals.Scatter(
  dt = NULL,
  AggMethod = "mean",
  SampleSize = 1e+05,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  MouseScroll = TRUE,
  Title = "Residual Scatterplot",
  ShowLabels = FALSE,
  Title.YAxis = "Target - Predicted",
  Title.XAxis = "Predicted",
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

MouseScroll

logical, zoom via mouse scroll

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

"Not Implemented"

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.River

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.River(
  dt = NULL,
  AggMethod = "mean",
  PreAgg = TRUE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "River Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  ShowSymbol = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name. You can supply multiple YVars

GroupVar

One Grouping Variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

"Title"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

Provide an "Echarts" theme

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

ShowSymbol

= FALSE

TextColor

"Not Implemented"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 1000)

# Build plot
AutoPlots::Plot.River(
  dt = data,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = "DateTime",
  YVar = c(
    "Independent_Variable1",
    "Independent_Variable2",
    "Independent_Variable3",
    "Independent_Variable4",
    "Independent_Variable5"),
  YVarTrans = "Identity",
  TextColor = "black",
  EchartsTheme = "macarons")

Plot.ROC

Description

ROC Plot

Usage

Plot.ROC(
  dt = NULL,
  SampleSize = 1e+05,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "ROC Plot",
  ShowLabels = FALSE,
  Title.YAxis = "True Positive Rate",
  Title.XAxis = "1 - False Positive Rate",
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

character

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

character hex

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance(), Plot.VariableImportance()


Plot.Rosetype

Description

Build a donut plot by simply passing arguments to a single function

Usage

Plot.Rosetype(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Donut Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo","essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired","jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal","sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

'darkblue'

title.fontSize

Defaults to size 22. Numeric. This changes the size of the title.

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
dt <- data.table::data.table(Y = qnorm(p = runif(10000)), GV = sample(LETTERS, 1000, TRUE))

# Create plot
AutoPlots::Plot.Rosetype(
  dt = dt,
  PreAgg = FALSE,
  XVar = "GV",
  YVar = "Y",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = 'mean',
  Height = NULL,
  Width = NULL,
  Title = 'Pie Chart',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE)

Plot.Scatter

Description

Build a copula plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Scatter(
  dt = NULL,
  SampleSize = 30000L,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Scatter Plot",
  ShowLabels = FALSE,
  AddGLM = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  tooltip.trigger = "axis",
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

numeric

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

character

ShowLabels

character

AddGLM

logical

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

character hex

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

tooltip.trigger

"axis"

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)
data[, Independent_Variable8 := Independent_Variable8 * runif(.N)]

# Echarts Scatter Plot Chart
AutoPlots::Plot.Scatter(
  dt = data,
  SampleSize = 10000,
  XVar = "Independent_Variable10",
  YVar = "Independent_Variable8",
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = 'Scatter Plot',
  ShowLabels = FALSE,
  AddGLM = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "blue",
  MouseScroll = TRUE,
  TimeLine = FALSE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  tooltip.trigger = "axis",
  Debug = FALSE)

Plot.Scatter3D

Description

Build a 3D-copula plot by simply passing arguments to a single function. It will sample your data using SampleSize number of rows. Sampled data is randomized.

Usage

Plot.Scatter3D(
  dt = NULL,
  SampleSize = 1e+05,
  XVar = NULL,
  YVar = NULL,
  ZVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "3D Scatter",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  zaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

SampleSize

An integer for the number of rows to use. Sampled data is randomized. If NULL then ignored

XVar

X-Axis variable name

YVar

Y-Axis variable name

ZVar

Z-Axis variable name

GroupVar

Requires an XVar and YVar already be defined

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

'Violin Plot'

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

= "macaron"

TimeLine

Logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

zaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

zaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter(), Plot.StackedBar(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)
data[, Independent_Variable9 := Independent_Variable9 * runif(.N)]

# Echarts Copula Plot Chart
AutoPlots::Plot.Scatter3D(
  dt = data,
  SampleSize = 10000,
  XVar = "Adrian",
  YVar = "Independent_Variable9",
  ZVar = "Independent_Variable6",
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  GroupVar = NULL,
  Height = NULL,
  Width = NULL,
  Title = 'Copula 3D',
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = FALSE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  zaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  zaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.ShapImportance

Description

Plot.ShapImportance variable importance

Usage

Plot.ShapImportance(
  dt,
  PreAgg = FALSE,
  AggMethod = "meanabs",
  YVar = NULL,
  GroupVar = NULL,
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumberBins = 21,
  NumLevels_X = 33,
  NumLevels_Y = 33,
  Height = NULL,
  Width = NULL,
  Title = "Shap Importance",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "dark",
  TextColor = "white",
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

AggMethod

"mean", "median", "sum", "sd", "skewness","kurtosis", "coeffvar", "meanabs", "medianabs", "sumabs", "sdabs", "skewnessabs", "kurtosisabs", "CoeffVarabs"

YVar

Names of shap columns

GroupVar

Name of by variable

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumberBins

= 21

NumLevels_X

= 20

NumLevels_Y

= 20

Height

"400px"

Width

"200px"

Title

"Heatmap"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"dark-blue"

TextColor

character

Debug

= FALSE

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.VariableImportance()


Plot.StackedBar

Description

Build a stacked bar plot vs a grouped bar plot

Usage

Plot.StackedBar(
  dt = NULL,
  PreAgg = FALSE,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Stacked Bar",
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  ShowLabels = FALSE,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

NULL

Width

NULL

Title

title

Title.YAxis

NULL. If NULL, YVar name will be used

Title.XAxis

NULL. If NULL, XVar name will be used

ShowLabels

logical

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

yaxis.fontSize

14

xaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.Step(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 100000)

# Echarts Stacked Bar Chart
AutoPlots::Plot.StackedBar(
  dt = data,
  PreAgg = FALSE,
  XVar = "Factor_1",
  YVar = "Adrian",
  GroupVar = "Factor_2",
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = 'mean',
  Height = NULL,
  Width = NULL,
  Title = "Stacked Bar",
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  ShowLabels = FALSE,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  yaxis.fontSize = 14,
  xaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plot.StandardPlots

Description

Helper for standard plots

Usage

Plot.StandardPlots(
  dt = NULL,
  PreAgg = FALSE,
  PlotType = "Scatter",
  SampleSize = 100000L,
  AggMethod = "mean",
  NumberBins = 30,
  YVar = NULL,
  DualYVar = NULL,
  XVar = NULL,
  ZVar = NULL,
  GroupVar = NULL,
  YVarTrans = NULL,
  DualYVarTrans = NULL,
  XVarTrans = NULL,
  ZVarTrans = NULL,
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  EchartsTheme = "dark-blue",
  MouseScroll = FALSE,
  TimeLine = FALSE,
  Title = NULL,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  NumLevels_Y = 75,
  NumLevels_X = 40,
  TextColor = "white",
  FontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

PreAgg

FALSE

PlotType

character

SampleSize

character

AggMethod

character

NumberBins

For histograms

YVar

Y-Axis variable name

DualYVar

Secondary Axis for Line, Step, and Area plots

XVar

X-Axis variable name

ZVar

Z-Axis variable name

GroupVar

Character variable variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

DualYVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

NULL or valid css unit

Width

NULL or valid css unit

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

MouseScroll

logical, zoom via mouse scroll

TimeLine

character

Title

character

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

NumLevels_Y

Numeric

NumLevels_X

Numeric

TextColor

character

FontSize

numeric

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Auto Plotting: Plots.ModelEvaluation()


Plot.Step

Description

This function automatically builds calibration plots and calibration boxplots for model evaluation using regression, quantile regression, and binary and multinomial classification

Usage

Plot.Step(
  dt = NULL,
  AggMethod = "mean",
  PreAgg = TRUE,
  XVar = NULL,
  YVar = NULL,
  DualYVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  DualYVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Line Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  MouseScroll = TRUE,
  TimeLine = TRUE,
  ShowSymbol = FALSE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

PreAgg

logical

XVar

X-Axis variable name

YVar

Y-Axis variable name. You can supply multiple YVars

DualYVar

Secondary Y-Axis variables. Leave NULL for no secondary axis. Only one variable is allowed and when this is set only one YVar is allowed. An error will be thrown if those conditions are not met

GroupVar

One Grouping Variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

DualYVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

Height

"400px"

Width

"200px"

Title

"Title"

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

Provide an "Echarts" theme

MouseScroll

logical, zoom via mouse scroll

TimeLine

Logical

ShowSymbol

= FALSE

TextColor

"Not Implemented"

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.WordCloud()

Examples

# Create fake data
data <- AutoPlots::FakeDataGenerator(N = 1000)

# Build plot
AutoPlots::Plot.Step(
  dt = data,
  PreAgg = FALSE,
  AggMethod = "mean",
  XVar = "DateTime",
  YVar = "Independent_Variable3",
  YVarTrans = "Identity",
  DualYVar = "Independent_Variable6",
  DualYVarTrans = "Identity",
  GroupVar = NULL,
  EchartsTheme = "macarons")

Plot.VariableImportance

Description

Generate variable importance plots

Usage

Plot.VariableImportance(
  dt = NULL,
  XVar = NULL,
  YVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  AggMethod = "mean",
  Height = NULL,
  Width = NULL,
  Title = "Variable Importance Plot",
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "macarons",
  TimeLine = TRUE,
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  Debug = FALSE
)

Arguments

dt

source data.table

XVar

Column name of X-Axis variable. If NULL then ignored

YVar

Column name of Y-Axis variable. If NULL then ignored

GroupVar

Column name of Group Variable for distinct colored histograms by group levels

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

AggMethod

Choose from 'mean', 'sum', 'sd', and 'median'

Height

"400px"

Width

"200px"

Title

title

ShowLabels

character

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

'darkblue'

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Model Evaluation: Plot.BinaryMetrics(), Plot.Calibration.Box(), Plot.Calibration.Line(), Plot.ConfusionMatrix(), Plot.Gains(), Plot.Lift(), Plot.PartialDependence.Box(), Plot.PartialDependence.HeatMap(), Plot.PartialDependence.Line(), Plot.ROC(), Plot.Residuals.Histogram(), Plot.Residuals.Scatter(), Plot.ShapImportance()


Plot.WordCloud

Description

WordCloud plots

Usage

Plot.WordCloud(
  dt = NULL,
  YVar = NULL,
  Height = NULL,
  Width = NULL,
  Title = "Word Cloud",
  EchartsTheme = "macarons",
  TextColor = "white",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = "#63aeff",
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE
)

Arguments

dt

source data.table

YVar

Y-Axis variable name

Height

"400px"

Width

"200px"

Title

= "Density Plot"

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TextColor

"white",

title.fontSize

22

title.fontWeight

"bold"

title.textShadowColor

'#63aeff'

title.textShadowBlur

3

title.textShadowOffsetY

1

title.textShadowOffsetX

-1

xaxis.fontSize

14

yaxis.fontSize

14

xaxis.rotate

0

yaxis.rotate

0

ContainLabel

TRUE

Debug

Debugging purposes

Value

plot

See Also

Other Standard Plots: Plot.ACF(), Plot.Area(), Plot.BarPlot3D(), Plot.Bar(), Plot.Box(), Plot.Copula3D(), Plot.Copula(), Plot.CorrMatrix(), Plot.Density(), Plot.Donut(), Plot.HeatMap(), Plot.Histogram(), Plot.Line(), Plot.PACF(), Plot.Parallel(), Plot.Pie(), Plot.ProbabilityPlot(), Plot.Radar(), Plot.River(), Plot.Rosetype(), Plot.Scatter3D(), Plot.Scatter(), Plot.StackedBar(), Plot.Step()

Examples

# Create fake data
dt <- FakeDataGenerator(AddComment = TRUE)

# Create plot
AutoPlots::Plot.WordCloud(
  dt = dt,
  YVar = "Comment",
  Height = NULL,
  Width = NULL,
  Title = "Word Cloud",
  EchartsTheme = "macarons",
  TextColor = "black",
  title.fontSize = 22,
  title.fontWeight = "bold",
  title.textShadowColor = '#63aeff',
  title.textShadowBlur = 3,
  title.textShadowOffsetY = 1,
  title.textShadowOffsetX = -1,
  xaxis.fontSize = 14,
  yaxis.fontSize = 14,
  xaxis.rotate = 0,
  yaxis.rotate = 0,
  ContainLabel = TRUE,
  Debug = FALSE)

Plots.ModelEvaluation

Description

Plot helper for model evaluation plot types

Usage

Plots.ModelEvaluation(
  dt = NULL,
  AggMethod = "mean",
  SampleSize = 100000L,
  PlotType = NULL,
  YVar = NULL,
  TargetLevel = NULL,
  ZVar = NULL,
  XVar = NULL,
  GroupVar = NULL,
  YVarTrans = "Identity",
  XVarTrans = "Identity",
  ZVarTrans = "Identity",
  FacetRows = 1,
  FacetCols = 1,
  FacetLevels = NULL,
  NumLevels_Y = 75,
  NumLevels_X = 40,
  MouseScroll = FALSE,
  Height = NULL,
  Width = NULL,
  Title = NULL,
  ShowLabels = FALSE,
  Title.YAxis = NULL,
  Title.XAxis = NULL,
  EchartsTheme = "dark-blue",
  TimeLine = FALSE,
  TextColor = "white",
  FontSize = 14L,
  NumberBins = 20,
  Debug = FALSE
)

Arguments

dt

source data.table

AggMethod

character

SampleSize

100000L

PlotType

character

YVar

Y-Axis variable name

TargetLevel

character

ZVar

Z-Axis variable name

XVar

X-Axis variable name

GroupVar

Character variable

YVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

XVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

ZVarTrans

"Asinh", "Log", "LogPlus1", "Sqrt", "Asin", "Logit", "PercRank", "Standardize", "BoxCox", "YeoJohnson"

FacetRows

Defaults to 1 which causes no faceting to occur vertically. Otherwise, supply a numeric value for the number of output grid rows

FacetCols

Defaults to 1 which causes no faceting to occur horizontally. Otherwise, supply a numeric value for the number of output grid columns

FacetLevels

Faceting rows x columns is the max number of levels allowed in a grid. If your GroupVar has more you can supply the levels to display.

NumLevels_Y

= 75

NumLevels_X

= 40

MouseScroll

logical, zoom via mouse scroll

Height

"400px"

Width

"200px"

Title

character

ShowLabels

logical

Title.YAxis

character

Title.XAxis

character

EchartsTheme

"auritus","azul","bee-inspired","blue","caravan","carp","chalk","cool","dark-bold","dark","eduardo", #' "essos","forest","fresh-cut","fruit","gray","green","halloween","helianthus","infographic","inspired", #' "jazz","london","dark","macarons","macarons2","mint","purple-passion","red-velvet","red","roma","royal", #' "sakura","shine","tech-blue","vintage","walden","wef","weforum","westeros","wonderland"

TimeLine

logical

TextColor

hex

FontSize

numeric

NumberBins

numeric

Debug

Debugging purposes

Value

plot

Author(s)

Adrian Antico

See Also

Other Auto Plotting: Plot.StandardPlots()