| Title: | Genotyping Triploids/Tetraploids (or Diploids) from Luminescence Data |
|---|---|
| Description: | Genotyping of triploid individuals from luminescence data (marker probeset A and B). Works also for diploids and tetraploids. Three main functions: Create_Dataset_from_file() to build dataset ; Clustering_parallele_from_dir() that regroups individuals with a same genotype based on proximity and Genotyping_parallele_from_dir() that assigns a genotype to each cluster. For Shiny interface use: launch_GenoShiny(). |
| Authors: | Julien Roche [aut, cre], Florence Phocas [aut], Mathieu Besson [aut], Pierre Patrice [aut], Marc Vandeputte [aut], François Allal [aut], Pierrick Haffray [aut] |
| Maintainer: | Julien Roche <[email protected]> |
| License: | GPL |
| Version: | 2.2.2 |
| Built: | 2026-10-13 20:38:44 UTC |
| Source: | https://github.com/cran/GenoTriplo |
Clustering function to run clustering with no parallelization process nor auto save
Clustering(data_clustering, nb_clust_possible, n_iter = 5, Dmin = 0.28)Clustering(data_clustering, nb_clust_possible, n_iter = 5, Dmin = 0.28)
data_clustering |
dataset with Contrast and SigStren for each individuals (as SampleName) and each markers (as MarkerName) |
nb_clust_possible |
number of cluster possible (ploidy+1) |
n_iter |
number of iterations to perform for clustering |
Dmin |
minimal distance between two clusters |
list of results of clustering
## Not run: file.create = system.file("extdata/output_create/1","1_1_to_clust.Rdata", package = "GenoTriplo") load(file.create) ploidy=3 Clustering(data_clustering=data_clustering,nb_clust_possible=ploidy+1) ## End(Not run)## Not run: file.create = system.file("extdata/output_create/1","1_1_to_clust.Rdata", package = "GenoTriplo") load(file.create) ploidy=3 Clustering(data_clustering=data_clustering,nb_clust_possible=ploidy+1) ## End(Not run)
Clustering function to run clustering with no parallelization process and autosave
Clustering_from_dir( dir_from_create, new.dir = NULL, ploidy, n_iter = 5, Dmin = 0.28 )Clustering_from_dir( dir_from_create, new.dir = NULL, ploidy, n_iter = 5, Dmin = 0.28 )
dir_from_create |
directory of the file to clusterize. |
new.dir |
new directory name for saving in './output_clustering' |
ploidy |
ploidy of individuals |
n_iter |
number of iterations to perform for clustering |
Dmin |
minimal distance between two clusters |
Autosave of the results in new.dir
## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") ploidy = 3 Clustering_from_dir(dir_from_create=dir.create,ploidy=ploidy) ## End(Not run)## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") ploidy = 3 Clustering_from_dir(dir_from_create=dir.create,ploidy=ploidy) ## End(Not run)
Clustering function to run clustering with no parallelization process and autosave Used by Clustering_from_dir. Shouldn't be used else.
Clustering_from_file( dirname, filename, ploidy, n_iter = 5, Dmin = 0.28, new.dir = NULL )Clustering_from_file( dirname, filename, ploidy, n_iter = 5, Dmin = 0.28, new.dir = NULL )
dirname |
directory of the file to clusterize. |
filename |
filename of the data to clusterize |
ploidy |
ploidy of individuals |
n_iter |
number of iterations to perform for clustering |
Dmin |
minimal distance between two clusters |
new.dir |
new directory name for saving |
Autosave of the results
## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") file.create = system.file("extdata/output_create/1","1_1_to_clust.Rdata", package = "GenoTriplo") ploidy=3 Clustering_from_file(dirname=dir.create,filename=file.create,ploidy=ploidy) ## End(Not run)## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") file.create = system.file("extdata/output_create/1","1_1_to_clust.Rdata", package = "GenoTriplo") ploidy=3 Clustering_from_file(dirname=dir.create,filename=file.create,ploidy=ploidy) ## End(Not run)
Launch the clustering phase in parallel from the dataset with SampleName, Contrast and SigStren for each markers (MarkerName).
Clustering_parallele_from_dir( dir_from_create, new.dir = NULL, ploidy, n_iter = 5, Dmin = 0.28, n_core = 1 )Clustering_parallele_from_dir( dir_from_create, new.dir = NULL, ploidy, n_iter = 5, Dmin = 0.28, n_core = 1 )
dir_from_create |
directory name with dataset files saved in './output_create' |
new.dir |
directory name where output is saved as in './output_clustering' |
ploidy |
ploidy of individuals |
n_iter |
number of iterations of clustering |
Dmin |
threshold distance between two clusters |
n_core |
number of cores used for parallelization |
the result of clustering or automatically save a list of objects if a saving name has been provided
## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") Clustering_parallele_from_dir(dir_from_create=dir.create,ploidy=3) ## End(Not run)## Not run: dir.create = system.file("extdata/output_create/1", package = "GenoTriplo") Clustering_parallele_from_dir(dir_from_create=dir.create,ploidy=3) ## End(Not run)
Create SigStren and Contrast variables from luminescence values of probeset A and B of each markers and return a dataframe to be used for clustering or save the result if a saving name is given
Create_Dataset_from_file( filename = "./AxiomGT1.summary.txt", dir.name = NULL, indiv_name = NULL, marker_name = NULL, n_marker_chunk = 4000, simplify.names = TRUE )Create_Dataset_from_file( filename = "./AxiomGT1.summary.txt", dir.name = NULL, indiv_name = NULL, marker_name = NULL, n_marker_chunk = 4000, simplify.names = TRUE )
filename |
filename from AXAS : |
dir.name |
saving name (the number of the chunk and _to_clust is automatically added) |
indiv_name |
vector with name of individuals to keep |
marker_name |
vector with name of marker to keep |
n_marker_chunk |
number of lines by chunk (have to be even as markers goes by pair) |
simplify.names |
Samplenames might be like so : IndivXX_a1_a1.CEL (if from Axiom) -> allows to select only IndivXX as SampleName |
save file in ./output_create/dir.name as k_to_clust.Rdata with k the chunk number.
## Not run: filepath = system.file("extdata", "AxiomGT1.summary_examples.txt", package = "GenoTriplo") Create_Dataset_from_file(filename=filepath) ## End(Not run)## Not run: filepath = system.file("extdata", "AxiomGT1.summary_examples.txt", package = "GenoTriplo") Create_Dataset_from_file(filename=filepath) ## End(Not run)
Create files of genotype and indiv/marker stats from genotype .Rdata files
create_genofiles(dir.name.save, new.dir, ploidy, corres_ATCG = NULL)create_genofiles(dir.name.save, new.dir, ploidy, corres_ATCG = NULL)
dir.name.save |
directory with .Rdata files with genotype |
new.dir |
new directory for saving files |
ploidy |
ploidy of the population |
corres_ATCG |
dataframe with correspondance between Allele_A/Allele_B to ATCG |
names of the indivCR and markerCR files
## Not run: ploidy = 3 dir.name.save = system.file("extdata/output_genotyping/1", package = "GenoTriplo") new.dir = "1" create_genofiles(dir.name.save=dir.name.save,new.dir=new.dir,ploidy=ploidy) ## End(Not run)## Not run: ploidy = 3 dir.name.save = system.file("extdata/output_genotyping/1", package = "GenoTriplo") new.dir = "1" create_genofiles(dir.name.save=dir.name.save,new.dir=new.dir,ploidy=ploidy) ## End(Not run)
Run genotyping from file
Genotyping_from_file( dirname, filename, new.dir = NULL, ploidy, SeuilNoCall = 0, SeuilNbSD = 2.8, SeuilSD = 0.28, cr_marker = 0.97, fld_marker = 3.4, hetso_marker = -0.3, same.pop = TRUE, tryEqHW = TRUE )Genotyping_from_file( dirname, filename, new.dir = NULL, ploidy, SeuilNoCall = 0, SeuilNbSD = 2.8, SeuilSD = 0.28, cr_marker = 0.97, fld_marker = 3.4, hetso_marker = -0.3, same.pop = TRUE, tryEqHW = TRUE )
dirname |
name of the directory where the file is |
filename |
name of the file with the data for genotyping |
new.dir |
new directory name for saving |
ploidy |
ploidy of individuals |
SeuilNoCall |
threshold of the probability of belonging to a cluster |
SeuilNbSD |
threshold for the distance between an individuals and his cluster (x=Contrast) |
SeuilSD |
threshold for the standard deviation of a cluster ( |
cr_marker |
call rate threshold |
fld_marker |
FLD threshold |
hetso_marker |
HetSO threshold |
same.pop |
Boolean : are individuals from a same population |
tryEqHW |
Only if same.pop==TRUE else ignore. If TRUE, will delete cluster that shouldn't happen under H-W equilibrium (heterozygote with less individuals than both homozygote in triploid for example). Additionnaly, the cluster should contain less than 5% of the individuals. Else it stays. |
Void. Save the results
## Not run: ploidy=3 dir_from_clustering=system.file("extdata/output_clustering/1", package = "GenoTriplo") file_from_clustering=system.file( "extdata/output_clustering/1", "1_1_to_geno.Rdata", package = "GenoTriplo") Genotyping_from_file(dirname=dir_from_clustering,ploidy=ploidy,filename=file_from_clustering) ## End(Not run)## Not run: ploidy=3 dir_from_clustering=system.file("extdata/output_clustering/1", package = "GenoTriplo") file_from_clustering=system.file( "extdata/output_clustering/1", "1_1_to_geno.Rdata", package = "GenoTriplo") Genotyping_from_file(dirname=dir_from_clustering,ploidy=ploidy,filename=file_from_clustering) ## End(Not run)
Function that launch the genotyping phase from the dataset with SampleName, Contrast and SigStren for each markers and the result of the 'Run_clustering' function.
Genotyping_parallele_from_dir( dir_from_clustering, new.dir = NULL, ploidy, SeuilNoCall = 0, SeuilNbSD = 2.8, SeuilSD = 0.28, n_core = 1, corres_ATCG = NULL, same.pop = TRUE, cr_marker = 0.97, fld_marker = 3.4, hetso_marker = -0.3, tryEqHW = TRUE )Genotyping_parallele_from_dir( dir_from_clustering, new.dir = NULL, ploidy, SeuilNoCall = 0, SeuilNbSD = 2.8, SeuilSD = 0.28, n_core = 1, corres_ATCG = NULL, same.pop = TRUE, cr_marker = 0.97, fld_marker = 3.4, hetso_marker = -0.3, tryEqHW = TRUE )
dir_from_clustering |
directory with files from clustering phase |
new.dir |
name of the new directory for saving results in './output_genotyping' |
ploidy |
ploidy of individuals |
SeuilNoCall |
threshold of the probability of belonging to a cluster |
SeuilNbSD |
threshold for the distance between an individuals and his cluster (x=Contrast) |
SeuilSD |
threshold for the standard deviation of a cluster (SeuilSD*(1+0.5*abs(mean_contrast_cluster))) |
n_core |
number of cores used for parallelization |
corres_ATCG |
dataframe with the correspondence between A/B of AXAS and A/T/C/G (three columns : probeset_id, Allele_A, Allele_B) |
same.pop |
Boolean : are individuals from a same population |
cr_marker |
call rate threshold |
fld_marker |
FLD threshold |
hetso_marker |
HetSO threshold |
tryEqHW |
Only if same.pop==TRUE else ignore. If TRUE, will delete cluster that shouldn't happen under H-W equilibrium (heterozygote with less individuals than both homozygote in triploid for example). Additionnaly, the cluster should contain less than 5% of the individuals. Else it stays. |
Void. Save the results.
## Not run: ploidy=3 dir_from_clustering=system.file("extdata/output_clustering/1", package = "GenoTriplo") Genotyping_parallele_from_dir(dir_from_clustering=dir_from_clustering,ploidy=ploidy) ## End(Not run)## Not run: ploidy=3 dir_from_clustering=system.file("extdata/output_clustering/1", package = "GenoTriplo") Genotyping_parallele_from_dir(dir_from_clustering=dir_from_clustering,ploidy=ploidy) ## End(Not run)
Launch a shiny interface to use GenoTriplo. Really easy to use and user friendly, this will help you gain time !
launch_GenoShiny()launch_GenoShiny()
void : most results are automatically saved
## Not run: launch_GenoShiny() ## End(Not run)## Not run: launch_GenoShiny() ## End(Not run)