Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gael MILLOT
cute_little_R_functions
Commits
ce5910dd
Commit
ce5910dd
authored
Oct 04, 2020
by
Gael
Browse files
fun_trim() bug fixed
parent
0ff9f35f
Changes
3
Hide whitespace changes
Inline
Side-by-side
cute_little_R_functions.R
View file @
ce5910dd
...
...
@@ -34,53 +34,53 @@
################ Object analysis 2
######## fun_check() #### check class, type, length, etc., of objects 2
######## fun_secu() #### verif that local variables are not present in other envs 1
0
######## fun_info() #### recover object information 1
2
######## fun_head() #### head of the left or right of big 2D objects 1
4
######## fun_tail() #### tail of the left or right of big 2D objects 1
5
######## fun_comp_1d() #### comparison of two 1D datasets (vectors, factors, 1D tables) 1
6
######## fun_comp_2d() #### comparison of two 2D datasets (row & col names, dimensions, etc.) 2
0
######## fun_comp_list() #### comparison of two lists 2
6
######## fun_test() #### test combinations of argument values of a function and return errors (and graphs)
29
################ Object modification 4
3
######## fun_name_change() #### check a vector of character strings and modify any string if present in another vector 4
3
######## fun_df_remod() #### remodeling a data frame to have column name as a qualitative values and vice-versa 4
5
######## fun_round() #### rounding number if decimal present
47
######## fun_mat_rotate() #### 90° clockwise matrix rotation
49
######## fun_mat_num2color() #### convert a numeric matrix into hexadecimal color matrix 5
0
######## fun_mat_op() #### assemble several matrices with operation 5
3
######## fun_mat_inv() #### return the inverse of a square matrix 5
6
######## fun_mat_fill() #### fill the empty half part of a symmetric square matrix
57
######## fun_permut() #### progressively breaks a vector order 6
1
######## fun_slide() #### return a computation made on a vector using a sliding window 7
1
################ Graphics management
7
8
######## fun_width() #### window width depending on classes to plot
7
8
######## fun_open() #### open a GUI or pdf graphic window 8
0
######## fun_prior_plot() #### set graph param before plotting (erase axes for instance) 8
4
######## fun_scale() #### select nice label numbers when setting number of ticks on an axis
88
######## fun_inter_ticks() #### define coordinates of secondary ticks 9
3
######## fun_post_plot() #### set graph param after plotting (axes redesign for instance)
97
######## fun_close() #### close specific graphic windows 1
08
################ Standard graphics 11
0
######## fun_empty_graph() #### text to display for empty graphs 11
0
################ gg graphics 11
2
######## fun_gg_palette() #### ggplot2 default color palette 11
2
######## fun_gg_just() #### ggplot2 justification of the axis labeling, depending on angle 11
3
######## fun_gg_get_legend() #### get the legend of ggplot objects 1
16
######## fun_gg_point_rast() #### ggplot2 raster scatterplot layer 1
18
######## fun_gg_boxplot() #### ggplot2 boxplot + background dots if required 12
1
######## fun_gg_scatter() #### ggplot2 scatterplot + lines (up to 6 overlays totally) 12
1
######## fun_gg_heatmap() #### ggplot2 heatmap + overlaid mask if required 1
22
######## fun_gg_empty_graph() #### text to display for empty graphs 13
5
################ Graphic extraction 1
37
######## fun_trim() #### display values from a quantitative variable and trim according to defined cut-offs 1
37
######## fun_segmentation() #### segment a dot cloud on a scatterplot and define the dots from another cloud outside the segmentation 14
6
################ Import 1
7
8
######## fun_pack() #### check if R packages are present and import into the working environment 1
7
8
######## fun_python_pack() #### check if python packages are present 1
8
0
################ Print / Exporting results (text & tables) 1
82
######## fun_report() #### print string or data object into output file 1
82
######## fun_get_message() #### return error/warning/other messages of an expression (that can be exported) 1
85
######## fun_secu() #### verif that local variables are not present in other envs 1
1
######## fun_info() #### recover object information 1
3
######## fun_head() #### head of the left or right of big 2D objects 1
5
######## fun_tail() #### tail of the left or right of big 2D objects 1
6
######## fun_comp_1d() #### comparison of two 1D datasets (vectors, factors, 1D tables) 1
7
######## fun_comp_2d() #### comparison of two 2D datasets (row & col names, dimensions, etc.) 2
1
######## fun_comp_list() #### comparison of two lists 2
9
######## fun_test() #### test combinations of argument values of a function and return errors (and graphs)
31
################ Object modification 4
6
######## fun_name_change() #### check a vector of character strings and modify any string if present in another vector 4
6
######## fun_df_remod() #### remodeling a data frame to have column name as a qualitative values and vice-versa 4
7
######## fun_round() #### rounding number if decimal present
50
######## fun_mat_rotate() #### 90° clockwise matrix rotation
52
######## fun_mat_num2color() #### convert a numeric matrix into hexadecimal color matrix 5
3
######## fun_mat_op() #### assemble several matrices with operation 5
6
######## fun_mat_inv() #### return the inverse of a square matrix 5
9
######## fun_mat_fill() #### fill the empty half part of a symmetric square matrix
60
######## fun_permut() #### progressively breaks a vector order 6
4
######## fun_slide() #### return a computation made on a vector using a sliding window 7
5
################ Graphics management 8
3
######## fun_width() #### window width depending on classes to plot 8
3
######## fun_open() #### open a GUI or pdf graphic window 8
5
######## fun_prior_plot() #### set graph param before plotting (erase axes for instance) 8
9
######## fun_scale() #### select nice label numbers when setting number of ticks on an axis
93
######## fun_inter_ticks() #### define coordinates of secondary ticks 9
8
######## fun_post_plot() #### set graph param after plotting (axes redesign for instance)
102
######## fun_close() #### close specific graphic windows 1
14
################ Standard graphics 11
6
######## fun_empty_graph() #### text to display for empty graphs 11
6
################ gg graphics 11
7
######## fun_gg_palette() #### ggplot2 default color palette 11
7
######## fun_gg_just() #### ggplot2 justification of the axis labeling, depending on angle 11
9
######## fun_gg_get_legend() #### get the legend of ggplot objects 1
24
######## fun_gg_point_rast() #### ggplot2 raster scatterplot layer 1
26
######## fun_gg_boxplot() #### ggplot2 boxplot + background dots if required 12
9
######## fun_gg_scatter() #### ggplot2 scatterplot + lines (up to 6 overlays totally) 12
9
######## fun_gg_heatmap() #### ggplot2 heatmap + overlaid mask if required 1
30
######## fun_gg_empty_graph() #### text to display for empty graphs 1
4
3
################ Graphic extraction 1
45
######## fun_trim() #### display values from a quantitative variable and trim according to defined cut-offs 1
45
######## fun_segmentation() #### segment a dot cloud on a scatterplot and define the dots from another cloud outside the segmentation 1
5
4
################ Import 1
8
8
######## fun_pack() #### check if R packages are present and import into the working environment 1
8
8
######## fun_python_pack() #### check if python packages are present 1
9
0
################ Print / Exporting results (text & tables) 1
93
######## fun_report() #### print string or data object into output file 1
93
######## fun_get_message() #### return error/warning/other messages of an expression (that can be exported) 1
96
################################ FUNCTIONS ################################
...
...
@@ -6058,7 +6058,7 @@ stop(paste0("\n\n================\n\n", tempo.cat, "\n\n================\n\n"),
}
# end argument checking
# main code
if(class(data)%in% c("matrix", "array")){
if(
all(
class(data)%in% c("matrix", "array"))
)
{
data <- as.vector(data)
}
na.nb <- NULL
...
...
@@ -7966,9 +7966,9 @@ return(output) # do not use cat() because the idea is to reuse the message
# check s/lapply everywhere with get: done cute boxplot scatter
# get() with env everywhere: done cute boxplot scatter
# add the new NA and NULL check cute,
boxplot, scatter: done boxplot, scatter
# check s/lapply everywhere with get: done cute boxplot scatter
anova comat
# get() with env everywhere: done cute boxplot scatter
anova comat
# add the new NA and NULL check cute,
done for all the rest
fun_gg_boxplot <- function(
data1,
...
...
cute_little_R_functions.docx
View file @
ce5910dd
No preview for this file type
fun_gg_boxplot.docx
View file @
ce5910dd
No preview for this file type
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment