Skip to content
This repository has been archived by the owner on Oct 16, 2024. It is now read-only.

Releases: TiagoOlivoto/metan

v1.8.1

11 Sep 02:06
Compare
Choose a tag to compare
  • Use \doi{} markup in Rd files.
  • New function gytb() to generate the Genotype by yield*trait biplot.
  • New functions row_col_mean() and row_col_sum()to add a row with the mean/sum of each variable and a column with the the mean/sum for each row of a matrix or data frame.
  • New functions has_zero(), remove_cols_zero(), remove_rows_zero(), select_cols_zero(), select_rows_zero(), and replace_zero() to deal with 0s in a data frame.
  • Fix bug of inconsistent color legend when plotting objects of class gge.
  • Include class gge and can_corr in get_model_data().
  • New argument position in plot.gamem() and plot.mtsi() to control the position adjustment of the bar plot.
  • New argument col.by in corr_plot() to map the color of the points by a categorical variable.
  • New argument use_data in functions mgidi(), fai_blup(), and Smith_Hazel() to control which data is used (BLUPs or phenotypic means) to compute the index.
  • inspect() now generate a warning if zero values are observed in data.

v1.7.0

23 Jul 18:48
Compare
Choose a tag to compare
  • New functions clip_read() and clip_write() to read from the clipboard and write to the clipboard, respectively.
  • New function sum_by() to compute the sum by levels of factors.
  • Update wsmp.R (#7). Thank you @BartoszKozak for your contribution.
  • mgidi() now allows using a fixed-effect model fitted with gafem() as input data.
  • round_cols() now can be used to round whole matrices.

v1.6.1

12 Jun 19:42
Compare
Choose a tag to compare
  • plot.mgidi() can now plot the contribution for all genotypes.
  • plot_bars() and plot_factbars() now shows the values with values = TRUE
  • Update the functions by using the new dplyr::across()
  • Update citation field by including number and version of the published paper.

v1.6.0

21 May 10:35
Compare
Choose a tag to compare

New functions

  • Smith_Hazel() and print.sh() and plot.sh() for computing the Smith and Hazel selection index.
  • coincidence_index() for computing the coincidence index.

Minor improvements

  • get_model_data() now extracts the genotypic and phenotypic variance-covariance matrix from objects of class gamem and waasb.
  • fai_blup() now returns the total genetic gain and the list with the ideotypes' construction.
  • mgidi() now computes the genetic gain when a mixed-model is used as input data.
  • The S3 method plot() for objects of class mgidi has a new argument type = "contribution" to plot the contribution of each factor in the MGIDI index.
  • plot_scores() now can produce a biplot showing other axes besides PC1 and PC2. To change the default IPCA in each axis use the new arguments first and second.

v1.5.0

12 Apr 23:56
Compare
Choose a tag to compare

New functions

  • select_rows_na() and select_cols_na() to select rows or columns with with NA values.
  • mgidi() to compute the multi-trait genotype-ideotype distance index.
  • plot_bars() to create bar plots quickly. Thanks to @MariaDiel for her suggestion.

Minor changes

  • Deprecated functions hm_mean() and gm_mean() removed in favour of hmean() and gmean(), respectively.
  • Deprecated argument rep retired in Fox(), ge_effects(), Huehn(), resp_surf(), superiority(), and Thennarasu()
  • Deprecated argument verbose retired in anova_ind()
  • Deprecated argument region retired in resp_surf()
  • Remove dependency on dendextend by using ggplot2-based graphics in plot.wsmp().
  • Update package site with pkgdown v1.5.0.
  • Update documentation in ge_plot()
  • Allow using fai_blup() with gamem()
  • Improve checking process with inspect()
  • Improve feedback for results, indicating random and fixed effects. Thanks to @NelsonJunior for his suggestion.
  • plot() call on objects of class gamem, waasb and waas now returns the variable names automatically. Thanks to @MdFarhad for suggesting me this change.
  • plot.gamem() and plot.waasb() have a new argument (type = "vcomp") to produce a plot showing the contribution of the variance components to the phenotypic variance
  • cv_ammi(), cv_ammif(), and cv_blup() now check for missing values and unbalanced data before computing the cross-validation. (#3)

Bug fixes

  • Fix problems from a recent upgrade of package tibble to version 3.0.0.
  • get_model_data() now fills rows that don't matches across columns with NA. Thanks to @MdFarhad for his report.
  • get_model_data() called now report mean squares, F-calculated and P-values for blocks within replicates in anova_ind().

v1.4.0

19 Mar 02:02
Compare
Choose a tag to compare

Bug fixes

  • Factor columns can now have custom names rather than ENV, GEN, and REP only (#2).

New functions

  • gmd() a shortcut to get_model_data()
  • gtb() to generate a genotype-by-trait biplot.
  • gamem_met() to analyze genotypes in multi-environment trials using mixed- or random-effect models allowing unbalanced data. Thanks to @EderOliveira for his e-mail.
  • has_class() to check if a class exists.
  • impute_missing_val() to impute missing values in a two-way table based on Expectation-Maximization algoritms.
  • non_collinear_vars() to select a set of predictors with minimal multicollinearity.
  • replace_na() to replace NA values quicly.
  • random_na() to generate random NA values based on a desired proportion.

Minor changes

  • gge(), performs_ammi(), waas(), and waasb() now handle with unbalanced data by implementing a low-rank matrix approximation using singular value decomposition to impute missing entires. Imputation generates a warning message.
  • NA values are checked and removed with a warning when computing stability indexes. Thanks to @MdFarhad for alerting me.
  • New argument plot_res in path_coeff() to create a residual plot of the multiple regression model.
  • Update the citation file to include the published official reference.
  • Argument verbose deprecated in functions anova_ind() and split_factors()
  • Argument rep deprecated in functions Fox(), Huehn(), superiority(), and Thennarasu().
  • Deprecated argument means_by removed in functions can_corr() and clustering().
  • Deprecated argument verbose removed in functions colindiag() and split_factors().
  • Deprecated argument values removed in functions desc_stat() and find_outliers().
  • Deprecated argument var removed in function desc_wider().
  • Remove dependency on lattice by using ggplot2 in plot.resp_surf().
  • An up-to-date cheat sheet was included.

v1.3.0

12 Feb 02:14
Compare
Choose a tag to compare

New functions

  • alpha_color() To get a semi-transparent color
  • gafem() To analyze genotypes using fixed-effect models.
  • residual_plots() A helper function to create residuals plots.
  • stars_pval() To generate significance stars from p-values
  • doo() An alternative to dplyr::do for doing anything

utils_stats

  • cv_by() For computing coefficient of variation by levels of a factor.
  • max_by() For computing maximum values by levels of a factor.
  • means_by() For computing arithmetic means by levels of a factor.
  • min_by() For computing minimum values by levels of a factor.
  • n_by() For getting the length.
  • sd_by() For computing sample standard deviation.
  • sem_by() For computing standard error of the mean by levels of a factor.
  • av_dev() computes the average absolute deviation.
  • ci_mean() computes the confidence interval for the mean.
  • cv() computes the coefficient of variation.
  • hm_mean(), gm_mean() computes the harmonic and geometric means, respectively. The harmonic mean is the reciprocal of the arithmetic mean of the reciprocals. The geometric mean is the nth root of n products.
  • kurt() computes the kurtosis like used in SAS and SPSS.
  • range_data() Computes the range of the values.
  • sd_amo(), sd_pop() Computes sample and populational standard deviation, respectively.
  • sem() computes the standard error of the mean.
  • skew() computes the skewness like used in SAS and SPSS.
  • sum_dev() computes the sum of the absolute deviations.
  • sum_sq_dev() computes the sum of the squared deviations.
  • var_amo(), var_pop() computes sample and populational variance.
  • valid_n() Return the valid (not NA) length of a data.

utils_rows_cols

  • colnames_to_lower(), colnames_to_upper(), and colnames_to_title() to translate column names to lower, upper and title cases quickly.

utils_num_str

  • all_lower_case(), all_upper_case(), and all_title_case() to translate strings vectors or character columns of a data frame to lower, upper and title cases, respectively.
  • tidy_strings() Tidy up characters strings, non-numeric columns, or any selected columns in a data frame by putting all word in upper case, replacing any space, tabulation, punctuation characters by '_', and putting '_' between lower and upper cases.
  • find_text_in_num() Find text fragments in columns assumed to be numeric. This is especially useful when everything() is used in argument resp to select the response variables.

New arguments

  • anova_ind(), anova_joint(), performs_ammi(), waas() and waasb(), now have the argument block to analyze data from trials conducted in an alpha-lattice design. Thanks to @myaseen208 for his suggestion regarding multi-environment trial analysis with alpha-lattice designs.
  • argument repel included in plot_scores() to control wheater the labels are repelled or not to avoid overlapping.

Deprecated arguments

Argument means_by was deprecated in functions can_corr() and clustering(). Use means_by() to pass data based on means of factor to these functions.

Minor changes

  • Change "#000000FF" with "#FFFFFF00" in transparent_color()
  • desc_stat() now handles grouped data passed from dplyr::group_by()
  • plot_scores() now support objects of class waas_mean.
  • Include inst/CITATION to return a reference paper with citation("metan").
  • Change 'PC2' with 'PC1' in y-axis of plot_scores(type = 2) (#1)
  • get_model_data() now support models of class anova_joint and gafem and extract random effects of models fitted with waasb() and gamem().
  • Update plot.waasb() and plot.gamem() to show distribution of random effects.
  • inspect(), cv_blup(), cv_ammif(), and cv_ammi() now generate a warning message saying that is not possible to compute cross-validation procedures in experiments with two replicates only. Thanks to @Vlatko for his email.
  • plot.wsmp() now returns heatmaps created with ggplot2. Thus, we removed dependency on gplots.
  • Vignettes updated

First release on CRAN

14 Jan 17:13
Compare
Choose a tag to compare

The first release of the package CRAN

v1.1.0

20 Nov 18:22
Compare
Choose a tag to compare

I'm very pleased to announce the release of metan 1.1.0, This is a minor release with bug fixes and new functions. The most important changes are described below.

  • New function corr_stab_ind() for computing Spearman's rank correlation between stability indexes;
  • New function corr_coef() for computing correlation coefficients and p-values;
  • New S3 method plot.corr_coef() for creating correlation heat maps;
  • New S3 method print.corr_coef() for printing correlation and p-values;
  • New helper functions make_lower_tri() and make_upper_tri() for creating lower and upper triangular matrices, respectively.
  • New helper function reorder_cormat() for reordering a correlation matrix according to the correlation coefficients;
  • Improve usability of get_model_data() by supporting new classes of models. Now, get_model_data() can be used to get all statistics or ranks computed with the wrapper function ge_stats().
  • arrange_ggplot() now support objects of class ggmatrix.
  • Change the default plot theme to theme_metan()
  • Update function's documentation;
  • Update vignettes.

v1.0.1

03 Nov 18:49
Compare
Choose a tag to compare
  • New function gamem() for analyzing genotypes in one-way trials using mixed-effect models;
  • New function desc_wider() to convert an output of the function desc_stat() to a 'wide' format;
  • New function Fox() for Stability analysis;
  • New function Shukla() for stability analysis;
  • New function to_factor() to quickly convert variables to factors;
  • Improve usability of get_model_data() function;
  • Update function's doccumentation;
  • Update vignettes;