学习资源Gwas

52 篇文章 6 订阅

Case
IS

0a017f15-1c6b-45e7-8d55-e0a71df1b2e8
AND

Data Category
IS

Transcriptome Profiling

https://portal.gdc.cancer.gov/auth/api/data?annotations=true&related_files=true

GWAS数据分析专题
https://mp.weixin.qq.com/s?src=11&timestamp=1623895271&ver=3135&signature=OSuxkA9VceIRaRGf1Xb-15Ybpedc6R8mdtboMoOosOn8VZ0FiN8ZSNmJwXbF-Yu7n0kKP185bDz2RP2v3aSwsRnOOVeMFRHnuWwP9XR9Xf2s9oxrdXaYHAKGMffH&new=1

http://genomicsclass.github.io/book/

https://lulab2.gitbook.io/teaching/part-iii.-ngs-data-analyses/6.rna-regulation-analyses/chimeric
https://file.biolab.si/biolab/supp/bi-cancer/projections/

dir <- system.file(package=“dagdata”) #extracts the location of package
list.files(dir)
list.files(file.path(dir,“extdata”)) #external data is in this directory
filename <- file.path(dir,“extdata/femaleMiceWeights.csv”)
dat <- read.csv(filename)

library(downloader)
url <- “https://raw.githubusercontent.com/genomicsclass/dagdata/master/inst/extdata/femaleMiceWeights.csv”
filename <- “femaleMiceWeights.csv”
download(url, destfile=filename)

filename <- “femaleMiceWeights.csv”
dat <- read.csv(filename)
head(dat) #In R Studio use View(dat)

library(dplyr)
chow <- filter(dat, Diet==“chow”) #keep only the ones with chow diet
head(chow)

chowVals <- select(chow,Bodyweight)
head(chowVals)

chowVals <- filter(dat, Diet==“chow”) %>% select(Bodyweight)
#, note that if dplyr receives a data.frame it will return a data.frame.
class(chowVals)

#we can apply the unlist function which turns lists, such as data.frames, into numeric vectors:

chowVals <- filter(dat, Diet==“chow”) %>% select(Bodyweight) %>% unlist
class( chowVals )
?unlist

control <- filter(dat,Diet==“chow”) %>% select(Bodyweight) %>% unlist
treatment <- filter(dat,Diet==“hf”) %>% select(Bodyweight) %>% unlist
print( mean(treatment) )
obsdiff <- mean(treatment) - mean(control)
print(obsdiff)

library(downloader)
url <- “https://raw.githubusercontent.com/genomicsclass/dagdata/master/inst/extdata/femaleControlsPopulation.csv”
filename <- “femaleControlsPopulation.csv”
if (!file.exists(filename)) download(url,destfile=filename)
population <- read.csv(filename)
population <- unlist(population) # turn it into a numeric

##Now let’s sample 12 mice three times and see how the average changes.

control <- sample(population,12)
mean(control)
control <- sample(population,12)
mean(control)
control <- sample(population,12)
mean(control)

##12 control mice
control <- sample(population,12)
##another 12 control mice that we act as if they were not
treatment <- sample(population,12)
print(mean(treatment) - mean(control))

n <- 10000
null <- vector(“numeric”,n)
for (i in 1:n) {
control <- sample(population,12)
treatment <- sample(population,12)
null[i] <- mean(treatment) - mean(control)
}

mean(null >= obsdiff)

library(UsingR)
x <- father.son$fheight
round(sample(x,10),1)
smallest <- floor( min(x) )
largest <- ceiling( max(x) )
values <- seq(smallest, largest,len=300)
heightecdf <- ecdf(x)
plot(values, heightecdf(values), type=“l”,
xlab=“a (Height in inches)”,ylab=“Pr(x <= a)”)

hist(x)

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值