p-value

Extract pvalue from glm

无人久伴 提交于 2019-12-02 21:53:24
I'm running many regressions and am only interested in the effect on the coefficient and p-value of one particular variable. So, in my script, I'd like to be able to just extract the p-value from the glm summary (getting the coefficient itself is easy). The only way I know of to view the p-value is using summary(myReg). Is there some other way? e.g.: fit <- glm(y ~ x1 + x2, myData) x1Coeff <- fit$coefficients[2] # only returns coefficient, of course x1pValue <- ??? I've tried treating fit$coefficients as a matrix, but am still unable to simply extract the p-value. Is it possible to do this?

What's the lowest number R will present before rounding to 0?

浪尽此生 提交于 2019-12-02 16:01:06
问题 I'm doing some statistical analysis with R software (bootstrapped Kolmogorov-Smirnov tests) of very large data sets, meaning that my p values are all incredibly small. I've Bonferroni corrected for the large number of tests that I've performed meaning that my alpha value is also very small in order to reject the null hypothesis. The problem is, R presents me with p values of 0 in some cases where the p value is presumably so small that it cannot be presented (these are usually for the very

What's the lowest number R will present before rounding to 0?

断了今生、忘了曾经 提交于 2019-12-02 12:01:33
I'm doing some statistical analysis with R software (bootstrapped Kolmogorov-Smirnov tests) of very large data sets, meaning that my p values are all incredibly small. I've Bonferroni corrected for the large number of tests that I've performed meaning that my alpha value is also very small in order to reject the null hypothesis. The problem is, R presents me with p values of 0 in some cases where the p value is presumably so small that it cannot be presented (these are usually for the very large sample sizes). While I can happily reject the null hypothesis for these tests, the data is for

automaticly add p-values to facet plot

橙三吉。 提交于 2019-12-01 10:29:14
I have made a facet plot below using the following command: ggplot(data, aes(factor(Length),logFC)), + geom_boxplot(fill = "grey90"), + coord_cartesian(ylim=c(-5,5)) + facet_grid(X~Modification) Is there a way to compute p-values for each boxplot and add them as geom_text above each boxplot. I want to compute a t-test and compare against y=0. My data looks like this: X Length logFC Modification Daub 26 -0.7307060811 NTA Daub 22 -0.3325621272 NTA Daub 22 -2.0579390395 NTA Daub 25 2.7199391457 NTA Daub 23 -0.0009869389 NTA Daub 25 -0.3318842493 NTA ... My error message: > data <- structure(list

automaticly add p-values to facet plot

徘徊边缘 提交于 2019-12-01 08:32:02
问题 I have made a facet plot below using the following command: ggplot(data, aes(factor(Length),logFC)), + geom_boxplot(fill = "grey90"), + coord_cartesian(ylim=c(-5,5)) + facet_grid(X~Modification) Is there a way to compute p-values for each boxplot and add them as geom_text above each boxplot. I want to compute a t-test and compare against y=0. My data looks like this: X Length logFC Modification Daub 26 -0.7307060811 NTA Daub 22 -0.3325621272 NTA Daub 22 -2.0579390395 NTA Daub 25 2.7199391457

Python sklearn - how to calculate p-values

感情迁移 提交于 2019-11-30 05:23:05
This is probably a simple question but I am trying to calculate the p-values for my features either using classifiers for a classification problem or regressors for regression. Could someone suggest what is the best method for each case and provide sample code? I want to just see the p-value for each feature rather than keep the k best / percentile of features etc as explained in the documentation. Thank you Just run the significance test on X, y directly. Example using 20news and chi2 : >>> from sklearn.datasets import fetch_20newsgroups_vectorized >>> from sklearn.feature_selection import

ggplot2: add p-values to the plot

血红的双手。 提交于 2019-11-28 21:34:23
I got this plot Using the code below library(dplyr) library(ggplot2) library(ggpmisc) df <- diamonds %>% dplyr::filter(cut%in%c("Fair","Ideal")) %>% dplyr::filter(clarity%in%c("I1" , "SI2" , "SI1" , "VS2" , "VS1", "VVS2")) %>% dplyr::mutate(new_price = ifelse(cut == "Fair", price* 0.5, price * 1.1)) formula <- y ~ x ggplot(df, aes(x= new_price, y= carat, color = cut)) + geom_point(alpha = 0.3) + facet_wrap(~clarity, scales = "free_y") + geom_smooth(method = "lm", formula = formula, se = F) + stat_poly_eq(aes(label = paste(..rr.label..)), label.x.npc = "right", label.y.npc = 0.15, formula =

R ggplot2 boxplots - ggpubr stat_compare_means not working properly

两盒软妹~` 提交于 2019-11-28 11:40:52
I am trying to add significance levels to my boxplots in the form of asterisks using ggplot2 and the ggpubr package, but I have many comparisons and I only want to show the significant ones. I try to use the option hide.ns=TRUE in stat_compare_means , but it clearly does not work , it might be a bug in the ggpubr package. Besides, you see that I leave out group "PGMC4" from the pairwise wilcox.test comparisons; how can I leave this group out also for the kruskal.test ? The last question I have is how the significance level works? As in * is significant below 0.05, ** below 0.025, *** below 0

ChIP-seq基本流程及工具

你说的曾经没有我的故事 提交于 2019-11-28 02:59:02
ChIP-seq数据分析整理 1.Alignment 2.Peak detection 3.Peak annotation 1. GO analysis 2. Pathway analysis 4.Differential analysis 5.Peak gene 6.Pathway analysis 7.Data visualization 1.Alignment base calling——Off-Line Basecaller software (OLB V1.8.0). Solexa CHASTITY quality filter【质量控制】 http://www.genomics.agilent.com/article.jsp?pageId=2213 BOWTIE software (V2.1.0) 2.Peak detection MACS v1.4 p-value 10^-5 3.Peak annotation UCSC RefSeq Peaks annotation TSS distribution heatmap Peak Distribution around TSS peak Distribution Pie Charts Peaks in promoter 1. GO analysis www.geneontology.org Biological

ggplot2: add p-values to the plot

强颜欢笑 提交于 2019-11-27 13:58:20
问题 I got this plot Using the code below library(dplyr) library(ggplot2) library(ggpmisc) df <- diamonds %>% dplyr::filter(cut%in%c("Fair","Ideal")) %>% dplyr::filter(clarity%in%c("I1" , "SI2" , "SI1" , "VS2" , "VS1", "VVS2")) %>% dplyr::mutate(new_price = ifelse(cut == "Fair", price* 0.5, price * 1.1)) formula <- y ~ x ggplot(df, aes(x= new_price, y= carat, color = cut)) + geom_point(alpha = 0.3) + facet_wrap(~clarity, scales = "free_y") + geom_smooth(method = "lm", formula = formula, se = F) +