plot_paraDistribution_byViolinPlots {CGNM} | R Documentation |

## plot_paraDistribution_byViolinPlots

### Description

Make violin plot to compare the initial distribution and distribition of the accepted approximate minimizers found by the CGNM. Bars in the violin plots indicates the interquartile range. The solid line connects the interquartile ranges of the initial distribution and the distribution of the accepted approximate minimizer at the final iterate. The blacklines connets the minimums and maximums of the initial distribution and the distribution of the accepted approximate minimizer at the final iterate. The black dots indicate the median.

### Usage

```
plot_paraDistribution_byViolinPlots(
CGNM_result,
indicesToInclude = NA,
ParameterNames = NA,
ReparameterizationDef = NA
)
```

### Arguments

`CGNM_result` |
(required input) |

`indicesToInclude` |
(default: NA) |

`ParameterNames` |
(default: NA) |

`ReparameterizationDef` |
(default: NA) |

### Value

*A ggplot object* including the violin plot, interquartile range and median, minimum and maximum.

### Examples

```
model_analytic_function=function(x){
observation_time=c(0.1,0.2,0.4,0.6,1,2,3,6,12)
Dose=1000
F=1
ka=x[1]
V1=x[2]
CL_2=x[3]
t=observation_time
Cp=ka*F*Dose/(V1*(ka-CL_2/V1))*(exp(-CL_2/V1*t)-exp(-ka*t))
log10(Cp)
}
observation=log10(c(4.91, 8.65, 12.4, 18.7, 24.3, 24.5, 18.4, 4.66, 0.238))
CGNM_result=Cluster_Gauss_Newton_method(
nonlinearFunction=model_analytic_function,
targetVector = observation,
initial_lowerRange = rep(0.01,3), initial_upperRange = rep(100,3),
lowerBound=rep(0,3), ParameterNames = c("Ka","V1","CL"),
num_iter = 10, num_minimizersToFind = 100, saveLog = FALSE)
plot_paraDistribution_byViolinPlots(CGNM_result)
plot_paraDistribution_byViolinPlots(CGNM_result,
ReparameterizationDef=c("log10(Ka)","log10(V1)","log10(CL)"))
```

*CGNM*version 0.9.0 Index]