Questions tagged [r]

Please supplement your question with a minimal reproducible example. Use dput() for data and specify all non-base packages with library calls. For statistical questions please use http://stats.stackexchange.com.

Filter by
Sorted by
Tagged with
1 vote
1 answer
30 views

R: How to measure mean of a column for every 10000 rows condition on other column?

I have a large bed-like dataframe with over 30 million rows. What is the best way to calculate the mean value of fourth column ...
Deb's user avatar
  • 211
-1 votes
1 answer
22 views

JbrowseR usage - get error with the simplest example

I took the simplest code from https://gmod.github.io/JBrowseR/: JBrowseR("ViewHg19", location = "10:29,838,737..29,838,819") I try to build a ...
miri's user avatar
  • 1
4 votes
0 answers
29 views

How do I get R to repeat the same sequence of commands to the 2000 rows of a dataframe (each row being turned into a vetor) to give me 2000 p values?

I'm quite new to R and biostatistics. I need to work out the p values from the survival analysis (log rank test) for two thousand possible different combinations of events over a 11 year period. I ...
GabbyG's user avatar
  • 41
1 vote
0 answers
19 views

How can I install the R package R4ClinicalTrial?

I want to install the package from https://rdrr.io/github/zhuob/R4ClinicalTrial/ ...
Cristian Riccio's user avatar
0 votes
0 answers
21 views

Gene set enrichment ontology analysis issue

I have been dealing with this problem for the past 48 hrs. I do not know what is it, which prevents the function from assessing the parameters it gets passed. ...
aleksk31's user avatar
0 votes
1 answer
16 views

multiplatt from indicspecies package not producing results for all groups

Based on presence absence data, I'm attempting to find indicator species for different sample sites. I have 25 different groups or "clusters" as I've labelled them. Running the R code below, ...
Rainman's user avatar
  • 171
1 vote
2 answers
52 views

Abnormal representation of differentially expressed genes in volcano plots located at the extremities

This question was also asked on reddit Does anyone know how to correct the abnormal genes that seemed to be located on the curves near the extremities? The analysis was done using R package edgeR on ...
Timi's user avatar
  • 51
2 votes
0 answers
38 views

Protein conservation analysis with trident scores in R script

I am currently working on analyzing protein conservation across amino acid positions using Trident scores as output from the MstatX tool. I have 40,000 Trident score files, each containing amino acid ...
C. Valera's user avatar
2 votes
1 answer
85 views

How to visualize unique and overlapping genes in upSet R plot

I am still a newbie in the field of bioinformatics. I have been attempting to visualize unique and common genes across six different tissues using the UpSetR plot ...
S'bonelo Glen Khumalo's user avatar
1 vote
1 answer
42 views

Extracting P-Values for Co-Expressed Genes Within WGCNA Modules

I'm facing a challenge regarding the extraction of co-expressing genes from each module. After identifying modules, I've been using exportNetworkToCytoscape to visualize genes that co-express together....
Mozart's user avatar
  • 13
1 vote
0 answers
24 views

Why my FeatureScatter looks so different, and what does that mean?

I' am doing a sc-Seq analysis on a dataset from 10x genomics, using Seurat. I followed the standard workflow and I also did it with the SCTransform workflow. The results are very different when I plot ...
Rodrigo Angel Hermoza Sanchez's user avatar
2 votes
0 answers
60 views

Different ClinVar classifications/SNPs are linked to the same rsid

I am using R to extract ClinVar classification of SNPs using rsid. Here's an example of my workflow: Patient data: Sample Func Gene Codon_Change dbSNPv151_GRCh38 Chr Start End Ref Obs Mary ...
benson23's user avatar
  • 171
3 votes
1 answer
78 views

How to calculate distance between two regions from bed like dataframe in R?

I'm wondering how can I calculate the distance between two regions from the bed (chr, start, ...
Deb's user avatar
  • 211
0 votes
0 answers
23 views

limma linear model with interaction

I want to run some epigenome wide association studies based on city and pollutant type, could you please suggest if I can get DNA methylation sites (CpG) association based on pollutant type for each ...
bioinfonext's user avatar
2 votes
1 answer
74 views

WGCNA: Extract genes within the different modules to create a dataframe with two columns

My inquiry pertains to WGCNA. After identifying the modules, I would like to extract genes within the different modules to create a dataframe with two columns: ...
nann's user avatar
  • 23
0 votes
1 answer
38 views

problem with feature counts of RNA bulk seq paired data- in Rsubread

I did manage to bild index file (from NCBI transcriptome) and perform alingment in Rsubread in R with my fq files. I did get BAM files as a result and no error. However i am having trouble with next ...
MKE1508's user avatar
1 vote
1 answer
45 views

LD local clump-GRCh38 bfile

I want to do LD local clumping. The tutorial (https://mrcieu.github.io/ieugwasr/articles/local_ld.html) teaches how to, but the downloaded bfile is GRch37. I followed this question to download GRch38. ...
Phylicia_SY's user avatar
0 votes
1 answer
74 views

Volcano Plot: How to show unique gene names in the plot?

I'm wondering how can I show unique gene names in the volcano plot. My data looks like, ...
Deb's user avatar
  • 211
1 vote
0 answers
44 views

What method uses "diverge probability" in RNA-Seq differential expression analysis?

I am replicating differential expression analysis from a paper (here) on RNA-Seq data. I extracted the regulated genes using DESeq2::results with a threshold of 1 ...
Hadeer Ibrahiem's user avatar
1 vote
1 answer
86 views

stacked barplot with error bars

I need to create a barplot with error bars, my data consists of 2 groups called "Genot", with 3 sub-groups "Suberin" for each, associated with a value "Percent". ...
user18598's user avatar
2 votes
1 answer
81 views

How to perform liftover from 38 to 37 in R?

I have some gwas summary statistics in GRCh38 that I want to lift to GRCh37. I am trying to liftover in R using this code: ...
DN1's user avatar
  • 45
1 vote
1 answer
33 views

PANTHER FUNCTIONAL CLASSIFICATION in R

Does anyone know of a way to programmatically get panther protein class terms and IDs for a gene list, in a way that the classification structure is preserved (PARENT CLASS + CHILD CLASS)? i.e. For a ...
ricardo3889's user avatar
0 votes
1 answer
102 views

Statistical approach to link DNA methylation with toxic element exposure and health outcome

I would be thankful to you if you can help with the statistical approach for case-control study to link DNA methylation (epic array) with toxic element exposure (arsenic) and health outcome (...
bioinfonext's user avatar
0 votes
1 answer
27 views

getting NCBI TAXname by R

I have a data frame on R, called qIns8, with 14 columns and 204 rows. the column called "subject tax id" has NCBI taxIDs for the corresponding row, I need a script to add another column to ...
Farzad Beikpour's user avatar
3 votes
1 answer
40 views

biomarRT conversion of symbols

I wanted to use the code to convert mouse to human symbol, but I have problem with the mirror, I've tried to establish another one, but continue to have the same problem. ...
María José's user avatar
1 vote
1 answer
51 views

Intepreting and applying ordinal logistic regression coefficients to calculate probabilities?

Can someone help hint me how I can interpret ordinal logistic regression coefficients and how I can use the .L, .Q and .C terms to calculate probabilities? I am analysing a dataset, where people ...
Charles's user avatar
  • 537
-2 votes
3 answers
84 views

Filtering columns from large file based on a column list

I have list of samples as a txt file and want to only keep these samples from this large file; column name is samples name in the large file. ...
bioinfonext's user avatar
1 vote
1 answer
92 views

Mendelian randomization

I would be thankful to you if you can help with how I can use MR from my case-control study to link DNA methylation (epic array) with toxic element exposure (arsenic) and health outcome (...
bioinfonext's user avatar
1 vote
0 answers
22 views

DNA methylation mediator analysis for environmental exposure and health outcome

We measured blood DNA methylation using epic array in 100 no-diabetic and 100 type 1 diatbetic patients matched for age, sex and smoking and also measured arsenic exposure using ICP-MS. Could you ...
bioinfonext's user avatar
1 vote
0 answers
25 views

How to make a POST "vep/:species/region" request that is able to accomodate multiple alternate alleles for a single variant?

There is an R code example on Ensembl's website on how to execute a POST "vep/:species/region" request for variants that only have one alternate allele. The part that holds the variant data ...
Derk's user avatar
  • 11
0 votes
0 answers
29 views

Calculating p-value and adjusted p-value for pre-normalized microarray data with fold change precalculated

I have a microarray dataset with two mutants dataset that has already been normalised, and the fold change values for each gene in each mutant versus the wild type have been calculated. I'm interested ...
shaimaa Hassan's user avatar
-1 votes
1 answer
39 views

error in downloading the annotation of sequences on NCBI

I have developed an R function to download the "organism" name of the numerous NCBI accession numbers which are already saved in an object. The function: ...
Farzad Beikpour's user avatar
1 vote
1 answer
65 views

seeing full results on R

running this code on R, using the Biostrings package, vmatchPattern("GAAGACCGAGGCCACGCGGAGTACGAACGAGGGTACAGTCTTC", mySeq) in the console, it writes: <...
Farzad Beikpour's user avatar
4 votes
1 answer
58 views

How can I incorporate wildcards in Snakemake in an R script?

I am facing the following issue: I have a rule in Snakemake that looks something like this: ...
Classy Q's user avatar
3 votes
1 answer
46 views

How can I export a pruned phylogenetic tree in nexus format in R?

I have a phylogenetic tree with a lot of different populations and I wanted to removes most of them and apply new names to the labels. I wrote this code: ...
Nickmofoe's user avatar
  • 339
1 vote
2 answers
133 views

Making a DNAStringSet object

I wish to download a fasta sequence from NCBI using "rentrez" package and then save it in an object, then I want to have this object as a DNAStringSet object to work on the sequence using &...
Farzad Beikpour's user avatar
1 vote
0 answers
89 views

Q-Q plots and the genomic inflation factor (k)

I have done the limma association analysis using below model design but not sure how to evaluate Potential systematic biases using Q-Q plots and the genomic inflation factor (k). Could you please ...
bioinfonext's user avatar
0 votes
1 answer
37 views

A function to produce M fragments of DNA with length of I

I want a script in R, which creates M fragments of DNA with a length of I but with GC content of >70% I know this gives ...
Zizogolu's user avatar
  • 2,148
1 vote
1 answer
37 views

Error importing Maximum Credibility Tree from BEAST into R using treeio's read.beast()

I've encountered an issue that I'm hoping someone can help with. I constructed a phylogenetic tree using BEAST1 and then extracted the Maximum Credibility Tree using treeannotator. I'm trying to ...
Gerald Vasquez Aleman's user avatar
0 votes
2 answers
84 views

How to calculate average from a column when consecutive cells are similar in different columns?

I wonder how can I calculate the average of column 7 (WPS_win) when consecutive cells in column 2, column 3, and column 1 are the same. The file is in bed format (tab-separated format). The original ...
Deb's user avatar
  • 211
2 votes
2 answers
517 views

How to fix "No gene can be mapped, Expected input gene ID, return NULL..." error in clusterProfiler?

I am trying EnrichKEGG on a few gene samples of genes to check it works before inputting the full genome: This is my data input as test.csv ...
reltubycul's user avatar
4 votes
1 answer
45 views

How to get cytoband and gene level copy number from genome wide SNP array copy number data?

I have (human) Illumina genome wide SNP array copy number data. For each SNP genomewide, I have Log R Ratio (LRR) and B Allele Frequency (BAF). What tool(s) can I use to get the integer copy numbers (...
Sylvia Rodriguez's user avatar
2 votes
0 answers
272 views

How to perform PCA on proteomic data set

I'm trying to perform Principal Component Analysis using R on a proteomics dataset. As the dataset contains a lot missing values I tried different approaches. I ran PCA using ...
Alicia's user avatar
  • 21
3 votes
1 answer
37 views

Why does the subset of rows that match a condition added by the rows that don't match a condition not add up to the total number of rows?

I need to match the external gene names of a table I have called (which has 1,000,000 entries) with their respective ensemble gene IDs. Here's a small subset of df: ...
Feynman's user avatar
  • 71
0 votes
0 answers
91 views

What is happening in the Zuker-Algorithm

I am trying to understand the Zuker Algorithm. What is happening during initialisation? I know in Nussinov the diagonal is filled with 0s. Are the diagonals filled with infinite energy during Zuker´s ...
Serij's user avatar
  • 1
2 votes
0 answers
189 views

otu_table from phyloseq object does not have correct abundance: all asv are "0" for specific group of samples

This question was also asked on stack overflow I have QIIME2 outputs (feature table, tree, taxonomy, and metadata) that I've imported into R using qiime2R (v. 0.99.6) ‘qza_to_phyloseq’ to create a ...
Geomicro's user avatar
  • 121
0 votes
1 answer
52 views

Scale on the y-axis in a tree rotated with 'layout_dendrogram()' using ggtree

I'm editing a time-scaled tree using ggtree. The dates are correctly adjusted when I apply the 'mrsd' command and 'theme_tree2()', but when I try to rotate the tree with 'layout_dendrogram()', the ...
Gerald Vasquez Aleman's user avatar
0 votes
1 answer
38 views

Try to understand better how to set out an effective sample size within the MetagenomSeq package in microbiome

Cross-posted on biostars: https://www.biostars.org/p/9572744/ I am trying to understand better what number to be used and how to put it in the function MRcoefs within the Metagenomeseq package in R ...
Mohamed Samir's user avatar
-1 votes
1 answer
86 views

What are the fastest way of feature selection in R for large dataset in Machine Learning?

I have about 100 data sets with over 100,000 rows and 27 predictor variables and multiple response variable on each dataset. I want to select the most essential Features for these datasets. I used ...
Deb's user avatar
  • 211
-1 votes
1 answer
360 views

WGCNA error: Length of colors vector not compatible with number of objects in 'order'

...
Dr Gutha Rajasekar's user avatar

1
2 3 4 5
19