Skip to content

Commit 0e4c87d

Browse files
committed
updated for new 75B sample analysis
1 parent 346caf6 commit 0e4c87d

File tree

8 files changed

+46
-6
lines changed

8 files changed

+46
-6
lines changed

12.persistent_otus

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ EOF
1515

1616
#head -1 $IN | awk '{ for (i = 2; i <= NF; ++i) print $i }' | sort -n | awk '{ printf("\t\t%s,\n", $1); }' >> $SQL
1717
#awk -F'\t' -v otu_table="$otu_table" '{ if (line >= 1) { printf("\t\tROUND((%s / (SELECT SUM(%s) FROM %s)) * 100, 2) AS \"%s.%s\",\n", $1, $1, otu_table, $2, $3); } ++line; }' $SAMPLE_INFO_SUBSET >> $SQL
18-
awk -F'\t' -v otu_table="$otu_table" '{ if (line >= 1) { printf("\t\t%s\",\n", $1); } ++line; }' $SAMPLE_INFO_SUBSET >> $SQL
18+
awk -F'\t' -v otu_table="$otu_table" '{ if (line >= 1) { printf("\t\t%s,\n", $1); } ++line; }' $SAMPLE_INFO_SUBSET >> $SQL
1919

2020
cat << EOF >> $SQL
2121
sequence

13.figures.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ library(RColorBrewer)
1010
library(ggplot2)
1111
#library(reshape)
1212

13-
columns_to_use <- 29
13+
columns_to_use <- 30
1414

1515
pdf("./13.figures.heatmap.pdf")
1616

14.diversity

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
3+
source globals
4+
5+
R --no-save < $0.R

14.diversity.R

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
library(vegan)
2+
#source("http://www.jennajacobs.org/R/rarefaction.txt")
3+
source("rarefaction.txt")
4+
5+
columns_to_use <- 29
6+
7+
d <- read.table("variableO2_illumina_analyses.xls", header=T, row.names=1, sep="\t")
8+
9+
raw_otus <- d[,1:columns_to_use]
10+
11+
dmat <- t(raw_otus)
12+
13+
H <- diversity(dmat)
14+
15+
write.table(H, file="14.Shannon_Weaver.alpha.tab", quote=F, sep="\t")
16+
17+
z <- betadiver(dmat, "z")
18+
19+
print(z)
20+
21+
#write.table(z, file="14.beta.tab", quote=F, sep="\t")
22+
23+
rf <- rarefy(dmat, min(rowSums(dmat)))
24+
25+
print(rf)
26+
27+
pdf("14.rarefaction.pdf")
28+
rfc <- rarefaction(dmat)
29+
30+
rfc$richness
31+
rfc$SE
32+
rfc$subsample
33+
34+
write.table(rfc$richness, file="14.richness.tab", quote=F, sep="\t")

EXECUTE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
JOBS="0.setup 1.quality_filter 2.dereplication 3.abundance_sort 4.cluster 5.chimera 6.number_otus 7.map 8.make_table 9.classify 10.database 11.join_to_RDP_class 12.persistent_otus 13.figures"
3+
JOBS="0.setup 1.quality_filter 2.dereplication 3.abundance_sort 4.cluster 5.chimera 6.number_otus 7.map 8.make_table 9.classify 10.database 11.join_to_RDP_class 12.persistent_otus 13.figures 14.diversity"
44

55
update_dependent=0
66

data/082214MC27Fillumina-mapping2.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@ O2_5A_15 CGTGAGAC AGRGTTTGATCMTGGCTCAG Ill27Fbar13 082214MC27Fillumina O2_5A_15
1212
O2_5B_15 CGTGATAA AGRGTTTGATCMTGGCTCAG Ill27Fbar14 082214MC27Fillumina O2_5B_15
1313
O2_5C_15 CGTGGGAC AGRGTTTGATCMTGGCTCAG Ill27Fbar15 082214MC27Fillumina O2_5C_15
1414
O2_75A_15 CGTAACCA AGRGTTTGATCMTGGCTCAG Ill27Fbar1 082214MC27Fillumina O2_75A_15
15-
O2_75B_15 CGTAAGAA AGRGTTTGATCMTGGCTCAG Ill27Fbar2 082214MC27Fillumina O2_75B_15
15+
O2_75B_15_ignore CGTAAGAA AGRGTTTGATCMTGGCTCAG Ill27Fbar2 082214MC27Fillumina O2_75B_15_ignore
1616
O2_75C_15 CGTACCCA AGRGTTTGATCMTGGCTCAG Ill27Fbar3 082214MC27Fillumina O2_75C_15

globals

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ CLFRJAR=$RDPT/classifier.jar
1313
HOST=`mysql_host`
1414
DB=variableO2_illumina_analyses
1515

16-
RUNS="082214MC27Fillumina 070314MC27Fillumina"
16+
RUNS="082214MC27Fillumina 070314MC27Fillumina 100814MC27Fillumina"
1717
PRIMER=AGRGTTTGATCMTGGCTCAG
1818

1919
TRUNCLEN=492
2020
MAXEE=0.5
21-
CLUSTER_IDENT=0.97
21+
CLUSTER_IDENT=0.95
2222

2323
SAMPLE_INFO=sample_info.xls
2424
SAMPLE_INFO_SUBSET=sample_info.subset.xls

sample_info.subset.xls

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,5 @@ O2_5A_15 5A 15
2727
O2_5B_15 5B 15
2828
O2_5C_15 5C 15
2929
O2_75A_15 75A 15
30+
O2_75B_15 75B 15
3031
O2_75C_15 75C 15

0 commit comments

Comments
 (0)