New version of pairing algorithm (alpha)
git-svn-id: https://www.grenoble.prabi.fr/svn/LECASofts/ecoPrimers/branches/eric-test@184 60f365c0-8329-0410-b2a4-ec073aeeaa1d
This commit is contained in:
BIN
src/ecoPrimer
BIN
src/ecoPrimer
Binary file not shown.
@ -75,7 +75,7 @@ void printcurrenttime ()
|
|||||||
/* Format and print the time, "ddd yyyy-mm-dd hh:mm:ss zzz" */
|
/* Format and print the time, "ddd yyyy-mm-dd hh:mm:ss zzz" */
|
||||||
ts = localtime(&now);
|
ts = localtime(&now);
|
||||||
strftime(buf, sizeof(buf), "%a %Y-%m-%d %H:%M:%S %Z", ts);
|
strftime(buf, sizeof(buf), "%a %Y-%m-%d %H:%M:%S %Z", ts);
|
||||||
fprintf(stderr,"#%d#, %s\n",now, buf);
|
fprintf(stderr,"#%d#, %s\n",(int)now, buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
void printcurrenttimeinmilli()
|
void printcurrenttimeinmilli()
|
||||||
@ -90,6 +90,9 @@ void printcurrenttimeinmilli()
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
|
|
||||||
|
#ifdef MASKEDCODE
|
||||||
|
|
||||||
void printpairs (pairscount_t pairs, poptions_t options, int32_t rankdbstats, uint32_t seqdbsize)
|
void printpairs (pairscount_t pairs, poptions_t options, int32_t rankdbstats, uint32_t seqdbsize)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
@ -98,9 +101,9 @@ void printpairs (pairscount_t pairs, poptions_t options, int32_t rankdbstats, ui
|
|||||||
double sens;
|
double sens;
|
||||||
double speci;
|
double speci;
|
||||||
float avg;
|
float avg;
|
||||||
|
|
||||||
quorumseqs = seqdbsize * 70 / 100;
|
quorumseqs = seqdbsize * 70 / 100;
|
||||||
|
|
||||||
printf("primer_1\tseq_1\tPrimer_2\tseq_2\tamplifia_count\t%s_snes\t%s_spe\tmin_l\tmax_l\tavr_l\n", options->taxonrank, options->taxonrank);
|
printf("primer_1\tseq_1\tPrimer_2\tseq_2\tamplifia_count\t%s_snes\t%s_spe\tmin_l\tmax_l\tavr_l\n", options->taxonrank, options->taxonrank);
|
||||||
|
|
||||||
for (i=0; i < pairs.paircount; i++)
|
for (i=0; i < pairs.paircount; i++)
|
||||||
@ -121,9 +124,12 @@ void printpairs (pairscount_t pairs, poptions_t options, int32_t rankdbstats, ui
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif /* MASKEDCODE */
|
||||||
|
|
||||||
/*updateseqparams: This function counts the insample and outsample sequences
|
/*updateseqparams: This function counts the insample and outsample sequences
|
||||||
* and with each sequences adds a tag of the taxon to which the sequence beongs*/
|
* and with each sequences adds a tag of the taxon to which the sequence beongs*/
|
||||||
void updateseqparams (pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxonomy,
|
|
||||||
|
void updateseqparams (pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxonomy,
|
||||||
poptions_t options, int32_t *insamples, int32_t *outsamples)
|
poptions_t options, int32_t *insamples, int32_t *outsamples)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
@ -131,7 +137,7 @@ void updateseqparams (pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxo
|
|||||||
ecotx_t *tmptaxon;
|
ecotx_t *tmptaxon;
|
||||||
|
|
||||||
for (i=0;i<seqdbsize;i++)
|
for (i=0;i<seqdbsize;i++)
|
||||||
{
|
{
|
||||||
seqdb[i]->isexample=isGoodTaxon(taxonomy,seqdb[i]->taxid,options);
|
seqdb[i]->isexample=isGoodTaxon(taxonomy,seqdb[i]->taxid,options);
|
||||||
if (seqdb[i]->isexample)
|
if (seqdb[i]->isexample)
|
||||||
(*insamples)++;
|
(*insamples)++;
|
||||||
@ -139,7 +145,7 @@ void updateseqparams (pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxo
|
|||||||
(*outsamples)++;
|
(*outsamples)++;
|
||||||
|
|
||||||
taxid = taxonomy->taxons->taxon[seqdb[i]->taxid].taxid;
|
taxid = taxonomy->taxons->taxon[seqdb[i]->taxid].taxid;
|
||||||
tmptaxon = eco_findtaxonbytaxid(taxonomy, taxid);
|
tmptaxon = eco_findtaxonbytaxid(taxonomy, taxid);
|
||||||
if (tmptaxon)
|
if (tmptaxon)
|
||||||
tmptaxon = eco_findtaxonatrank(tmptaxon, options->taxonrankidx);
|
tmptaxon = eco_findtaxonatrank(tmptaxon, options->taxonrankidx);
|
||||||
if (tmptaxon)
|
if (tmptaxon)
|
||||||
@ -154,7 +160,7 @@ void setresulttaxonrank (ecotaxonomy_t *taxonomy, poptions_t options)
|
|||||||
/*set taxon rank for which result is to be given*/
|
/*set taxon rank for which result is to be given*/
|
||||||
for (i = 0; i < taxonomy->ranks->count; i++)
|
for (i = 0; i < taxonomy->ranks->count; i++)
|
||||||
{
|
{
|
||||||
if (strcmp(taxonomy->ranks->label[i], options->taxonrank) == 0)
|
if (strcmp(taxonomy->ranks->label[i], options->taxonrank) == 0)
|
||||||
{
|
{
|
||||||
options->taxonrankidx = i;
|
options->taxonrankidx = i;
|
||||||
break;
|
break;
|
||||||
@ -168,7 +174,7 @@ void setresulttaxonrank (ecotaxonomy_t *taxonomy, poptions_t options)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* to get db stats, totals of species, genus etc....*/
|
/* to get db stats, totals of species, genus etc....*/
|
||||||
int32_t getrankdbstats(pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxonomy,
|
int32_t getrankdbstats(pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *taxonomy,
|
||||||
poptions_t options)
|
poptions_t options)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
@ -177,7 +183,7 @@ int32_t getrankdbstats(pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *tax
|
|||||||
uint32_t namesindex = 0;
|
uint32_t namesindex = 0;
|
||||||
int32_t *ranktaxonids = ECOMALLOC(nameslots * sizeof(int32_t), "Error in taxon rank allocation");
|
int32_t *ranktaxonids = ECOMALLOC(nameslots * sizeof(int32_t), "Error in taxon rank allocation");
|
||||||
int32_t taxid;
|
int32_t taxid;
|
||||||
|
|
||||||
ecotx_t *tmptaxon;
|
ecotx_t *tmptaxon;
|
||||||
|
|
||||||
for (i=0;i<seqdbsize;i++)
|
for (i=0;i<seqdbsize;i++)
|
||||||
@ -193,7 +199,7 @@ int32_t getrankdbstats(pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *tax
|
|||||||
if (tmptaxon->taxid == ranktaxonids[j]) break;
|
if (tmptaxon->taxid == ranktaxonids[j]) break;
|
||||||
}
|
}
|
||||||
if (j < namesindex) continue; /* name is already in list, so no need to add it*/
|
if (j < namesindex) continue; /* name is already in list, so no need to add it*/
|
||||||
|
|
||||||
if (namesindex == nameslots)
|
if (namesindex == nameslots)
|
||||||
{
|
{
|
||||||
nameslots += 500;
|
nameslots += 500;
|
||||||
@ -204,11 +210,13 @@ int32_t getrankdbstats(pecodnadb_t seqdb, uint32_t seqdbsize, ecotaxonomy_t *tax
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
ECOFREE(ranktaxonids, "free rank taxon table");
|
ECOFREE(ranktaxonids, "free rank taxon table");
|
||||||
|
|
||||||
return namesindex;
|
return namesindex;
|
||||||
}
|
}
|
||||||
|
|
||||||
void setoktaxforspecificity (ppairscount_t pairs)
|
#ifdef MASKEDCODE
|
||||||
|
|
||||||
|
void setoktaxforspecificity (ppairtree_t pairs)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
uint32_t j;
|
uint32_t j;
|
||||||
@ -216,7 +224,7 @@ void setoktaxforspecificity (ppairscount_t pairs)
|
|||||||
uint32_t l;
|
uint32_t l;
|
||||||
int taxcount;
|
int taxcount;
|
||||||
int32_t taxid;
|
int32_t taxid;
|
||||||
|
|
||||||
for (i = 0; i < pairs->paircount; i++)
|
for (i = 0; i < pairs->paircount; i++)
|
||||||
{
|
{
|
||||||
for (j = 0; j < pairs->pairs[i].taxsetindex; j++)
|
for (j = 0; j < pairs->pairs[i].taxsetindex; j++)
|
||||||
@ -235,13 +243,13 @@ void setoktaxforspecificity (ppairscount_t pairs)
|
|||||||
taxcount += pairs->pairs[i].ampset[l].seqidindex;
|
taxcount += pairs->pairs[i].ampset[l].seqidindex;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (taxid != pairs->pairs[i].ampset[l].taxonids[0])
|
if (taxid != pairs->pairs[i].ampset[l].taxonids[0])
|
||||||
{
|
{
|
||||||
if (!taxid) taxid = pairs->pairs[i].ampset[l].taxonids[0];
|
if (!taxid) taxid = pairs->pairs[i].ampset[l].taxonids[0];
|
||||||
taxcount++;
|
taxcount++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (taxcount > 1) break;
|
if (taxcount > 1) break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -251,6 +259,8 @@ void setoktaxforspecificity (ppairscount_t pairs)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
int main(int argc, char **argv)
|
int main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
pecodnadb_t seqdb; /* of type ecoseq_t */
|
pecodnadb_t seqdb; /* of type ecoseq_t */
|
||||||
@ -264,11 +274,11 @@ int main(int argc, char **argv)
|
|||||||
int32_t insamples=0;
|
int32_t insamples=0;
|
||||||
int32_t outsamples=0;
|
int32_t outsamples=0;
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
|
|
||||||
pwordcount_t words;
|
pwordcount_t words;
|
||||||
pprimercount_t primers;
|
pprimercount_t primers;
|
||||||
pairscount_t pairs;
|
ppairtree_t pairs;
|
||||||
|
|
||||||
int32_t rankdbstats = 0;
|
int32_t rankdbstats = 0;
|
||||||
|
|
||||||
//printcurrenttime();
|
//printcurrenttime();
|
||||||
@ -337,7 +347,7 @@ int main(int argc, char **argv)
|
|||||||
strncpy(options.taxonrank, optarg, 19);
|
strncpy(options.taxonrank, optarg, 19);
|
||||||
options.taxonrank[19] = 0;
|
options.taxonrank[19] = 0;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
/* -------------------- */
|
/* -------------------- */
|
||||||
case 'x': /* strict matching quorum */
|
case 'x': /* strict matching quorum */
|
||||||
/* -------------------- */
|
/* -------------------- */
|
||||||
@ -396,16 +406,16 @@ int main(int argc, char **argv)
|
|||||||
fprintf(stderr,"Reading taxonomy database ...");
|
fprintf(stderr,"Reading taxonomy database ...");
|
||||||
taxonomy = read_taxonomy(options.prefix,0);
|
taxonomy = read_taxonomy(options.prefix,0);
|
||||||
fprintf(stderr,"Ok\n");
|
fprintf(stderr,"Ok\n");
|
||||||
|
|
||||||
setresulttaxonrank(taxonomy, &options); /*TR: set rank level for statistics*/
|
setresulttaxonrank(taxonomy, &options); /*TR: set rank level for statistics*/
|
||||||
|
|
||||||
fprintf(stderr,"Reading sequence database ...\n");
|
fprintf(stderr,"Reading sequence database ...\n");
|
||||||
|
|
||||||
seqdb = readdnadb(options.prefix,&seqdbsize);
|
seqdb = readdnadb(options.prefix,&seqdbsize);
|
||||||
|
|
||||||
fprintf(stderr,"Ok\n");
|
fprintf(stderr,"Ok\n");
|
||||||
fprintf(stderr,"Sequence read : %d\n",(int32_t)seqdbsize);
|
fprintf(stderr,"Sequence read : %d\n",(int32_t)seqdbsize);
|
||||||
|
|
||||||
updateseqparams(seqdb, seqdbsize, taxonomy, &options, &insamples , &outsamples);
|
updateseqparams(seqdb, seqdbsize, taxonomy, &options, &insamples , &outsamples);
|
||||||
|
|
||||||
rankdbstats = getrankdbstats(seqdb, seqdbsize, taxonomy, &options);
|
rankdbstats = getrankdbstats(seqdb, seqdbsize, taxonomy, &options);
|
||||||
@ -419,7 +429,7 @@ int main(int argc, char **argv)
|
|||||||
printcurrenttimeinmilli();
|
printcurrenttimeinmilli();
|
||||||
words = lookforStrictPrimer(seqdb,seqdbsize,insamples,&options);
|
words = lookforStrictPrimer(seqdb,seqdbsize,insamples,&options);
|
||||||
printcurrenttimeinmilli();
|
printcurrenttimeinmilli();
|
||||||
|
|
||||||
fprintf(stderr,"\n Strict primer count : %d\n",words->size);
|
fprintf(stderr,"\n Strict primer count : %d\n",words->size);
|
||||||
|
|
||||||
if (options.no_multi_match)
|
if (options.no_multi_match)
|
||||||
@ -460,13 +470,14 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
pairs = buildPrimerPairs(seqdb, seqdbsize, primers, &options);
|
pairs = buildPrimerPairs(seqdb, seqdbsize, primers, &options);
|
||||||
setoktaxforspecificity (&pairs);
|
|
||||||
|
// setoktaxforspecificity (&pairs);
|
||||||
printpairs (pairs, &options, rankdbstats, seqdbsize);
|
|
||||||
|
// printpairs (pairs, &options, rankdbstats, seqdbsize);
|
||||||
|
|
||||||
|
|
||||||
ECOFREE(pairs.pairs,"Free pairs table");
|
|
||||||
|
//ECOFREE(pairs.pairs,"Free pairs table");
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@ LIBPATH= -Llibapat -LlibecoPCR -Llibecoprimer
|
|||||||
MAKEDEPEND = gcc -D$(MACHINE) -M $(CPPFLAGS) -o $*.d $<
|
MAKEDEPEND = gcc -D$(MACHINE) -M $(CPPFLAGS) -o $*.d $<
|
||||||
|
|
||||||
CC=gcc
|
CC=gcc
|
||||||
CFLAGS= -W -Wall -O5 -m64 -fast -g
|
CFLAGS= -W -Wall -O3 -m64 -fast -g
|
||||||
#CFLAGS= -W -Wall -O0 -m64 -g
|
#CFLAGS= -W -Wall -O0 -m64 -g
|
||||||
#CFLAGS= -W -Wall -O5 -fast -g
|
#CFLAGS= -W -Wall -O5 -fast -g
|
||||||
|
|
||||||
|
15
src/libecoPCR/ecoError.P
Normal file
15
src/libecoPCR/ecoError.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
ecoError.o ecoError.P : ecoError.c ecoPCR.h /usr/include/stdio.h \
|
||||||
|
/usr/include/_types.h /usr/include/sys/_types.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h /usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
15
src/libecoPCR/ecoIOUtils.P
Normal file
15
src/libecoPCR/ecoIOUtils.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
ecoIOUtils.o ecoIOUtils.P : ecoIOUtils.c ecoPCR.h /usr/include/stdio.h \
|
||||||
|
/usr/include/_types.h /usr/include/sys/_types.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h /usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
15
src/libecoPCR/ecoMalloc.P
Normal file
15
src/libecoPCR/ecoMalloc.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
ecoMalloc.o ecoMalloc.P : ecoMalloc.c ecoPCR.h /usr/include/stdio.h \
|
||||||
|
/usr/include/_types.h /usr/include/sys/_types.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h /usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
5
src/libecoPCR/ecodna.P
Normal file
5
src/libecoPCR/ecodna.P
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
ecodna.o ecodna.P : ecodna.c /usr/include/string.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h ecoPCR.h \
|
||||||
|
/usr/include/stdio.h /usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h
|
5
src/libecoPCR/ecofilter.P
Normal file
5
src/libecoPCR/ecofilter.P
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
ecofilter.o ecofilter.P : ecofilter.c ecoPCR.h /usr/include/stdio.h \
|
||||||
|
/usr/include/_types.h /usr/include/sys/_types.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h /usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h
|
15
src/libecoPCR/econame.P
Normal file
15
src/libecoPCR/econame.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
econame.o econame.P : econame.c ecoPCR.h /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/string.h /usr/include/stdlib.h /usr/include/available.h \
|
||||||
|
/usr/include/sys/wait.h /usr/include/sys/signal.h \
|
||||||
|
/usr/include/sys/appleapiopts.h /usr/include/machine/signal.h \
|
||||||
|
/usr/include/i386/signal.h /usr/include/i386/_structs.h \
|
||||||
|
/usr/include/sys/_structs.h /usr/include/machine/_structs.h \
|
||||||
|
/usr/include/mach/i386/_structs.h /usr/include/sys/resource.h \
|
||||||
|
/usr/include/machine/endian.h /usr/include/i386/endian.h \
|
||||||
|
/usr/include/sys/_endian.h /usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
15
src/libecoPCR/ecorank.P
Normal file
15
src/libecoPCR/ecorank.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
ecorank.o ecorank.P : ecorank.c ecoPCR.h /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/string.h /usr/include/stdlib.h /usr/include/available.h \
|
||||||
|
/usr/include/sys/wait.h /usr/include/sys/signal.h \
|
||||||
|
/usr/include/sys/appleapiopts.h /usr/include/machine/signal.h \
|
||||||
|
/usr/include/i386/signal.h /usr/include/i386/_structs.h \
|
||||||
|
/usr/include/sys/_structs.h /usr/include/machine/_structs.h \
|
||||||
|
/usr/include/mach/i386/_structs.h /usr/include/sys/resource.h \
|
||||||
|
/usr/include/machine/endian.h /usr/include/i386/endian.h \
|
||||||
|
/usr/include/sys/_endian.h /usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
19
src/libecoPCR/ecoseq.P
Normal file
19
src/libecoPCR/ecoseq.P
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
ecoseq.o ecoseq.P : ecoseq.c ecoPCR.h /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/string.h /usr/include/zlib.h /usr/include/zconf.h \
|
||||||
|
/usr/include/sys/types.h /usr/include/unistd.h \
|
||||||
|
/usr/include/sys/unistd.h /usr/include/sys/select.h \
|
||||||
|
/usr/include/sys/_select.h
|
15
src/libecoPCR/ecotax.P
Normal file
15
src/libecoPCR/ecotax.P
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
ecotax.o ecotax.P : ecotax.c ecoPCR.h /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/string.h /usr/include/stdlib.h /usr/include/available.h \
|
||||||
|
/usr/include/sys/wait.h /usr/include/sys/signal.h \
|
||||||
|
/usr/include/sys/appleapiopts.h /usr/include/machine/signal.h \
|
||||||
|
/usr/include/i386/signal.h /usr/include/i386/_structs.h \
|
||||||
|
/usr/include/sys/_structs.h /usr/include/machine/_structs.h \
|
||||||
|
/usr/include/mach/i386/_structs.h /usr/include/sys/resource.h \
|
||||||
|
/usr/include/machine/endian.h /usr/include/i386/endian.h \
|
||||||
|
/usr/include/sys/_endian.h /usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h
|
@ -10,6 +10,7 @@ SOURCES = goodtaxon.c \
|
|||||||
queue.c \
|
queue.c \
|
||||||
libstki.c \
|
libstki.c \
|
||||||
sortmatch.c \
|
sortmatch.c \
|
||||||
|
pairtree.c \
|
||||||
pairs.c \
|
pairs.c \
|
||||||
apat_search.c
|
apat_search.c
|
||||||
|
|
||||||
|
131
src/libecoprimer/amplifiatree.c
Normal file
131
src/libecoprimer/amplifiatree.c
Normal file
@ -0,0 +1,131 @@
|
|||||||
|
/*
|
||||||
|
* amplifiatree.c
|
||||||
|
*
|
||||||
|
* Created on: 7 mars 2009
|
||||||
|
* Author: coissac
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "ecoprimer.h"
|
||||||
|
#include <search.h>
|
||||||
|
|
||||||
|
static void cleanamplifia(pamplifia_t amplifia);
|
||||||
|
static void deleteamplifialist(pamplifialist_t list);
|
||||||
|
static int cmpamplifia(const void* p1,const void*p2);
|
||||||
|
|
||||||
|
|
||||||
|
static void cleanamplifiatlist(pamplifiacount_t list)
|
||||||
|
{
|
||||||
|
if (list->amplifias)
|
||||||
|
ECOFREE(list->amplifias,
|
||||||
|
"Free amplifia list");
|
||||||
|
}
|
||||||
|
|
||||||
|
static void cleanamplifia(pamplifia_t amplifia)
|
||||||
|
{
|
||||||
|
cleanamplifiatlist(&(amplifia->pcr));
|
||||||
|
}
|
||||||
|
|
||||||
|
static pamplifialist_t newamplifialist(pamplifialist_t parent, size_t size)
|
||||||
|
{
|
||||||
|
pamplifialist_t tmp;
|
||||||
|
|
||||||
|
tmp=ECOMALLOC(sizeof(amplifialist_t)+sizeof(amplifia_t)*(size-1),
|
||||||
|
"Cannot allocate new amplifia list");
|
||||||
|
|
||||||
|
tmp->amplifiaslots=size;
|
||||||
|
tmp->amplifiacount=0;
|
||||||
|
tmp->next=NULL;
|
||||||
|
|
||||||
|
if (parent)
|
||||||
|
parent->next=(void*)tmp;
|
||||||
|
|
||||||
|
return tmp;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void deleteamplifialist(pamplifialist_t list)
|
||||||
|
{
|
||||||
|
size_t i;
|
||||||
|
|
||||||
|
if (list)
|
||||||
|
{
|
||||||
|
if (list->next)
|
||||||
|
{
|
||||||
|
deleteamplifialist(list->next);
|
||||||
|
list->next=NULL;
|
||||||
|
}
|
||||||
|
for (i=0; i < list->amplifiacount; i++)
|
||||||
|
cleanamplifia((list->amplifias)+i);
|
||||||
|
|
||||||
|
ECOFREE(list,"Delete amplifia list");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
static int cmpamplifia(const void* p1,const void*p2)
|
||||||
|
{
|
||||||
|
pamplifia_t pr1,pr2;
|
||||||
|
|
||||||
|
pr1=(pamplifia_t)p1;
|
||||||
|
pr2=(pamplifia_t)p2;
|
||||||
|
|
||||||
|
if (pr1->p1 < pr2->p1) return -1;
|
||||||
|
if (pr1->p1 > pr2->p1) return 1;
|
||||||
|
|
||||||
|
if (pr1->asdirect1 < pr2->asdirect1) return -1;
|
||||||
|
if (pr1->asdirect1 > pr2->asdirect1) return 1;
|
||||||
|
|
||||||
|
if (pr1->p2 < pr2->p2) return -1;
|
||||||
|
if (pr1->p2 > pr2->p2) return 1;
|
||||||
|
|
||||||
|
if (pr1->asdirect2 < pr2->asdirect2) return -1;
|
||||||
|
if (pr1->asdirect2 > pr2->asdirect2) return 1;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
pamplifia_t amplifiaintree (amplifia_t key,
|
||||||
|
pamplifiatree_t amplifialist)
|
||||||
|
{
|
||||||
|
if (!amplifialist->tree)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
return *((pamplifia_t*)tsearch((const void *)(&key),
|
||||||
|
&(amplifialist->tree),
|
||||||
|
cmpamplifia
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
pamplifia_t insertamplifia(amplifia_t key,
|
||||||
|
pamplifiatree_t list)
|
||||||
|
{
|
||||||
|
pamplifia_t current;
|
||||||
|
pamplifia_t found;
|
||||||
|
|
||||||
|
if (list->last->amplifiacount==list->last->amplifiaslots)
|
||||||
|
{
|
||||||
|
list->last->next=newamplifialist(list,100);
|
||||||
|
list->last=list->last->next;
|
||||||
|
}
|
||||||
|
|
||||||
|
current = list->last->amplifias + list->last->amplifiacount;
|
||||||
|
*current=key;
|
||||||
|
|
||||||
|
found = *((pamplifia_t*)tsearch((const void *)current,
|
||||||
|
&(list->tree),
|
||||||
|
cmpamplifia));
|
||||||
|
if (found==current)
|
||||||
|
list->last->amplifiacount++;
|
||||||
|
|
||||||
|
return found;
|
||||||
|
}
|
||||||
|
|
||||||
|
pamplifiatree_t initamplifiatree(pamplifiatree_t tree)
|
||||||
|
{
|
||||||
|
if (!tree)
|
||||||
|
tree = ECOMALLOC(sizeof(amplifiatree_t),"Cannot allocate amplifia tree");
|
||||||
|
|
||||||
|
tree->first=newamplifialist(NULL,500);
|
||||||
|
tree->last=tree->first;
|
||||||
|
|
||||||
|
tree->tree=NULL;
|
||||||
|
}
|
17
src/libecoprimer/apat_search.P
Normal file
17
src/libecoprimer/apat_search.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
apat_search.o apat_search.P : apat_search.c /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/string.h libstki.h ecotype.h apat.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
../libecoPCR/ecoPCR.h
|
17
src/libecoprimer/aproxpattern.P
Normal file
17
src/libecoprimer/aproxpattern.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
aproxpattern.o aproxpattern.P : aproxpattern.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/math.h /usr/include/architecture/i386/math.h
|
@ -79,28 +79,39 @@ typedef union {
|
|||||||
uint32_t value;
|
uint32_t value;
|
||||||
} poslist_t, *ppostlist_t;
|
} poslist_t, *ppostlist_t;
|
||||||
|
|
||||||
typedef struct {
|
/**
|
||||||
word_t word;
|
* primer_t structure store fuzzy match positions for a primer
|
||||||
uint32_t *directCount;
|
* on all sequences
|
||||||
ppostlist_t directPos;
|
*/
|
||||||
|
|
||||||
uint32_t *reverseCount;
|
typedef struct {
|
||||||
ppostlist_t reversePos;
|
word_t word; //< code for the primer
|
||||||
bool_t good;
|
uint32_t *directCount; //< Occurrence count on direct strand
|
||||||
uint32_t inexample;
|
ppostlist_t directPos; //< list of position list on direct strand
|
||||||
uint32_t outexample;
|
|
||||||
|
uint32_t *reverseCount; //< Occurrence count on reverse strand
|
||||||
|
ppostlist_t reversePos; //< list of position list on reverse strand
|
||||||
|
|
||||||
|
bool_t good; //< primer match more than quorum example and no
|
||||||
|
// more counterexample quorum.
|
||||||
|
|
||||||
|
uint32_t inexample; //< count of example sequences matching primer
|
||||||
|
uint32_t outexample; //< count of counterexample sequences matching primer
|
||||||
} primer_t, *pprimer_t;
|
} primer_t, *pprimer_t;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* primercount_t structure store fuzzy match positions for all primers
|
||||||
|
* on all sequences as a list of primer_t
|
||||||
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
pprimer_t primers;
|
pprimer_t primers;
|
||||||
uint32_t size;
|
uint32_t size;
|
||||||
} primercount_t, *pprimercount_t;
|
} primercount_t, *pprimercount_t;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
word_t word;
|
pprimer_t primer;
|
||||||
uint32_t position;
|
uint32_t position;
|
||||||
bool_t strand;
|
bool_t strand;
|
||||||
bool_t good; /*TR: Added*/
|
|
||||||
} primermatch_t, *pprimermatch_t;
|
} primermatch_t, *pprimermatch_t;
|
||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
@ -109,6 +120,19 @@ typedef struct {
|
|||||||
uint32_t matchcount;
|
uint32_t matchcount;
|
||||||
} primermatchcount_t, *pprimermatchcount_t;
|
} primermatchcount_t, *pprimermatchcount_t;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
pecoseq_t sequence;
|
||||||
|
bool_t strand;
|
||||||
|
const char *amplifia;
|
||||||
|
int32_t length;
|
||||||
|
} amplifia_t, *pamplifia_t;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
pamplifia_t amplifias;
|
||||||
|
uint32_t ampcount;
|
||||||
|
uint32_t ampslot;
|
||||||
|
} amplifiacount_t, *pamplifiacount_t;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
char *amplifia;
|
char *amplifia;
|
||||||
int32_t *taxonids;
|
int32_t *taxonids;
|
||||||
@ -124,30 +148,51 @@ typedef struct {
|
|||||||
} taxampset_t, *ptaxampset_t;
|
} taxampset_t, *ptaxampset_t;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
word_t w1;
|
pprimer_t p1;
|
||||||
word_t w2;
|
bool_t asdirect1;
|
||||||
uint32_t inexample; /*inexample count*/
|
pprimer_t p2;
|
||||||
uint32_t outexample; /*outexample count*/
|
bool_t asdirect2;
|
||||||
|
|
||||||
uint32_t mind;
|
amplifiacount_t pcr;
|
||||||
uint32_t maxd;
|
|
||||||
|
uint32_t inexample; //< example sequence count
|
||||||
uint32_t ampsetcount;
|
uint32_t outexample; //< counterexample sequence count
|
||||||
uint32_t ampsetindex;
|
|
||||||
pampseqset_t ampset;
|
|
||||||
|
|
||||||
uint32_t taxsetcount;
|
// these statistics are relative to inexample sequences
|
||||||
uint32_t taxsetindex;
|
|
||||||
ptaxampset_t taxset;
|
uint32_t mind; //< minimum distance between primers
|
||||||
|
uint32_t maxd; //< maximum distance between primers
|
||||||
uint32_t oktaxoncount;
|
uint32_t sumd; //< distance sum
|
||||||
} pairs_t, *ppairs_t;
|
|
||||||
|
//
|
||||||
|
// uint32_t ampsetcount;
|
||||||
|
// uint32_t ampsetindex;
|
||||||
|
// pampseqset_t ampset;
|
||||||
|
//
|
||||||
|
// uint32_t taxsetcount;
|
||||||
|
// uint32_t taxsetindex;
|
||||||
|
// ptaxampset_t taxset;
|
||||||
|
//
|
||||||
|
// uint32_t oktaxoncount;
|
||||||
|
|
||||||
|
} pair_t, *ppair_t;
|
||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
ppairs_t pairs;
|
size_t paircount;
|
||||||
uint32_t paircount;
|
size_t pairslots;
|
||||||
}pairscount_t, *ppairscount_t;
|
void* next;
|
||||||
|
pair_t pairs[1];
|
||||||
|
} pairlist_t, *ppairlist_t;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
ppairlist_t first;
|
||||||
|
ppairlist_t last;
|
||||||
|
void *tree;
|
||||||
|
} pairtree_t, *ppairtree_t;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
pword_t words;
|
pword_t words;
|
||||||
@ -232,7 +277,12 @@ pprimercount_t lookforAproxPrimer(pecodnadb_t database, uint32_t seqdbsize,uint3
|
|||||||
|
|
||||||
void sortmatch(pprimermatch_t table,uint32_t N);
|
void sortmatch(pprimermatch_t table,uint32_t N);
|
||||||
|
|
||||||
|
ppairtree_t initpairtree(ppairtree_t tree);
|
||||||
|
ppair_t pairintree (pair_t key,ppairtree_t pairlist);
|
||||||
|
ppair_t insertpair(pair_t key,ppairtree_t list);
|
||||||
|
|
||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
pairscount_t buildPrimerPairs(pecodnadb_t seqdb,uint32_t seqdbsize,pprimercount_t primers,poptions_t options);
|
ppairtree_t buildPrimerPairs(pecodnadb_t seqdb,uint32_t seqdbsize,pprimercount_t primers,poptions_t options);
|
||||||
|
|
||||||
#endif /* EPSORT_H_ */
|
#endif /* EPSORT_H_ */
|
||||||
|
17
src/libecoprimer/goodtaxon.P
Normal file
17
src/libecoprimer/goodtaxon.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
goodtaxon.o goodtaxon.P : goodtaxon.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h
|
17
src/libecoprimer/hashsequence.P
Normal file
17
src/libecoprimer/hashsequence.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
hashsequence.o hashsequence.P : hashsequence.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h
|
17
src/libecoprimer/libstki.P
Normal file
17
src/libecoprimer/libstki.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
libstki.o libstki.P : libstki.c /usr/include/stdio.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/string.h libstki.h ecotype.h ecoprimer.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
../libecoPCR/ecoPCR.h apat.h debug.h
|
17
src/libecoprimer/merge.P
Normal file
17
src/libecoprimer/merge.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
merge.o merge.P : merge.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h
|
17
src/libecoprimer/pairs.P
Normal file
17
src/libecoprimer/pairs.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
pairs.o pairs.P : pairs.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/string.h
|
@ -7,34 +7,40 @@
|
|||||||
|
|
||||||
#include "ecoprimer.h"
|
#include "ecoprimer.h"
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
primermatchcount_t buildPrimerPairsForOneSeq(uint32_t seqid,pprimercount_t primers,poptions_t options);
|
static void buildPrimerPairsForOneSeq(uint32_t seqid,
|
||||||
|
pecodnadb_t seqdb,
|
||||||
|
pprimercount_t primers,
|
||||||
|
ppairtree_t pairs,
|
||||||
|
poptions_t options);
|
||||||
|
|
||||||
int32_t pairinlist (ppairs_t pairlist, word_t w1, word_t w2, uint32_t size)
|
|
||||||
{
|
|
||||||
uint32_t i;
|
|
||||||
|
|
||||||
for (i = 0; i < size; i++)
|
|
||||||
{
|
|
||||||
if (w1 == pairlist[i].w1 && w2 == pairlist[i].w2) return i;
|
|
||||||
if (w1 == pairlist[i].w2 && w2 == pairlist[i].w1) return i;
|
|
||||||
}
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
char *addamplifiasetelem (ppairs_t pair, char* amplifia, int32_t taxid)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*************************************
|
||||||
|
*
|
||||||
|
* pair collection management
|
||||||
|
*
|
||||||
|
*************************************/
|
||||||
|
|
||||||
|
#ifdef MASKEDCODE
|
||||||
|
|
||||||
|
char *addamplifiasetelem (ppair_t pair, char* amplifia, int32_t taxid)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
uint32_t j;
|
uint32_t j;
|
||||||
char *ampused = NULL;
|
char *ampused = NULL;
|
||||||
|
|
||||||
if(pair->ampsetcount == 0)
|
if(pair->ampsetcount == 0)
|
||||||
{
|
{
|
||||||
pair->ampsetcount = 500;
|
pair->ampsetcount = 500;
|
||||||
pair->ampsetindex = 0;
|
pair->ampsetindex = 0;
|
||||||
pair->ampset = ECOMALLOC(pair->ampsetcount * sizeof(ampseqset_t),"Cannot allocate amplifia set");
|
pair->ampset = ECOMALLOC(pair->ampsetcount * sizeof(ampseqset_t),"Cannot allocate amplifia set");
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < pair->ampsetindex; i++)
|
for (i = 0; i < pair->ampsetindex; i++)
|
||||||
{
|
{
|
||||||
if (strcmp (pair->ampset[i].amplifia, amplifia) == 0)
|
if (strcmp (pair->ampset[i].amplifia, amplifia) == 0)
|
||||||
@ -43,43 +49,43 @@ char *addamplifiasetelem (ppairs_t pair, char* amplifia, int32_t taxid)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (i == 0)
|
if (i == 0)
|
||||||
{
|
{
|
||||||
pair->ampset[i].seqidcount = 100;
|
pair->ampset[i].seqidcount = 100;
|
||||||
pair->ampset[i].seqidindex = 0;
|
pair->ampset[i].seqidindex = 0;
|
||||||
pair->ampset[i].taxonids = ECOMALLOC(pair->ampset[i].seqidcount * sizeof(uint32_t),"Cannot allocate amplifia sequence table");
|
pair->ampset[i].taxonids = ECOMALLOC(pair->ampset[i].seqidcount * sizeof(uint32_t),"Cannot allocate amplifia sequence table");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->ampsetindex == pair->ampsetcount)
|
if (pair->ampsetindex == pair->ampsetcount)
|
||||||
{
|
{
|
||||||
pair->ampsetcount += 500;
|
pair->ampsetcount += 500;
|
||||||
pair->ampset = ECOREALLOC(pair->ampset, pair->ampsetcount * sizeof(ampseqset_t), "Cannot allocate amplifia set");
|
pair->ampset = ECOREALLOC(pair->ampset, pair->ampsetcount * sizeof(ampseqset_t), "Cannot allocate amplifia set");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->ampset[i].seqidindex == pair->ampset[i].seqidcount)
|
if (pair->ampset[i].seqidindex == pair->ampset[i].seqidcount)
|
||||||
{
|
{
|
||||||
pair->ampset[i].seqidcount += 100;
|
pair->ampset[i].seqidcount += 100;
|
||||||
pair->ampset[i].taxonids = ECOREALLOC(pair->ampset[i].taxonids, pair->ampset[i].seqidcount * sizeof(int32_t), "Cannot allocate amplifia sequence table");
|
pair->ampset[i].taxonids = ECOREALLOC(pair->ampset[i].taxonids, pair->ampset[i].seqidcount * sizeof(int32_t), "Cannot allocate amplifia sequence table");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->ampset[i].amplifia == NULL)
|
if (pair->ampset[i].amplifia == NULL)
|
||||||
{
|
{
|
||||||
pair->ampset[i].amplifia = amplifia;
|
pair->ampset[i].amplifia = amplifia;
|
||||||
pair->ampsetindex++;
|
pair->ampsetindex++;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (j = 0; j < pair->ampset[i].seqidindex; j++)
|
for (j = 0; j < pair->ampset[i].seqidindex; j++)
|
||||||
{
|
{
|
||||||
if (pair->ampset[i].taxonids[j] == taxid) break;
|
if (pair->ampset[i].taxonids[j] == taxid) break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (j == pair->ampset[i].seqidindex)
|
if (j == pair->ampset[i].seqidindex)
|
||||||
pair->ampset[i].taxonids[pair->ampset[i].seqidindex++] = taxid;
|
pair->ampset[i].taxonids[pair->ampset[i].seqidindex++] = taxid;
|
||||||
return ampused;
|
return ampused;
|
||||||
}
|
}
|
||||||
|
|
||||||
void addtaxampsetelem (ppairs_t pair, int32_t taxid, char *amplifia)
|
void addtaxampsetelem (ppair_t pair, int32_t taxid, char *amplifia)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
uint32_t j;
|
uint32_t j;
|
||||||
@ -90,42 +96,42 @@ void addtaxampsetelem (ppairs_t pair, int32_t taxid, char *amplifia)
|
|||||||
pair->taxsetindex = 0;
|
pair->taxsetindex = 0;
|
||||||
pair->taxset = ECOMALLOC(pair->taxsetcount * sizeof(taxampset_t),"Cannot allocate taxon set");
|
pair->taxset = ECOMALLOC(pair->taxsetcount * sizeof(taxampset_t),"Cannot allocate taxon set");
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < pair->taxsetindex; i++)
|
for (i = 0; i < pair->taxsetindex; i++)
|
||||||
{
|
{
|
||||||
if (pair->taxset[i].taxonid == taxid) break;
|
if (pair->taxset[i].taxonid == taxid) break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (i == 0)
|
if (i == 0)
|
||||||
{
|
{
|
||||||
pair->taxset[i].amplifiacount = 100;
|
pair->taxset[i].amplifiacount = 100;
|
||||||
pair->taxset[i].amplifiaindex = 0;
|
pair->taxset[i].amplifiaindex = 0;
|
||||||
pair->taxset[i].amplifia = ECOMALLOC(pair->taxset[i].amplifiacount * sizeof(char *),"Cannot allocate amplifia table");
|
pair->taxset[i].amplifia = ECOMALLOC(pair->taxset[i].amplifiacount * sizeof(char *),"Cannot allocate amplifia table");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->taxsetindex == pair->taxsetcount)
|
if (pair->taxsetindex == pair->taxsetcount)
|
||||||
{
|
{
|
||||||
pair->taxsetcount += 500;
|
pair->taxsetcount += 500;
|
||||||
pair->taxset = ECOREALLOC(pair->taxset, pair->taxsetcount * sizeof(taxampset_t), "Cannot allocate taxon set");
|
pair->taxset = ECOREALLOC(pair->taxset, pair->taxsetcount * sizeof(taxampset_t), "Cannot allocate taxon set");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->taxset[i].amplifiaindex == pair->taxset[i].amplifiacount)
|
if (pair->taxset[i].amplifiaindex == pair->taxset[i].amplifiacount)
|
||||||
{
|
{
|
||||||
pair->taxset[i].amplifiacount += 100;
|
pair->taxset[i].amplifiacount += 100;
|
||||||
pair->taxset[i].amplifia = ECOREALLOC(pair->taxset[i].amplifia, pair->taxset[i].amplifiacount * sizeof(char *), "Cannot allocate amplifia table");
|
pair->taxset[i].amplifia = ECOREALLOC(pair->taxset[i].amplifia, pair->taxset[i].amplifiacount * sizeof(char *), "Cannot allocate amplifia table");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pair->taxset[i].taxonid == 0)
|
if (pair->taxset[i].taxonid == 0)
|
||||||
{
|
{
|
||||||
pair->taxset[i].taxonid = taxid;
|
pair->taxset[i].taxonid = taxid;
|
||||||
pair->taxsetindex++;
|
pair->taxsetindex++;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (j = 0; j < pair->taxset[i].amplifiaindex; j++)
|
for (j = 0; j < pair->taxset[i].amplifiaindex; j++)
|
||||||
{
|
{
|
||||||
if (strcmp(pair->taxset[i].amplifia[j], amplifia) == 0) break;
|
if (strcmp(pair->taxset[i].amplifia[j], amplifia) == 0) break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (j == pair->taxset[i].amplifiaindex)
|
if (j == pair->taxset[i].amplifiaindex)
|
||||||
{
|
{
|
||||||
pair->taxset[i].amplifia[j] = amplifia;
|
pair->taxset[i].amplifia[j] = amplifia;
|
||||||
@ -135,16 +141,18 @@ void addtaxampsetelem (ppairs_t pair, int32_t taxid, char *amplifia)
|
|||||||
|
|
||||||
char *getamplifia (pecoseq_t seq, uint32_t start, uint32_t len)
|
char *getamplifia (pecoseq_t seq, uint32_t start, uint32_t len)
|
||||||
{
|
{
|
||||||
|
fprintf(stderr,"start : %d length : %d\n",start,len);
|
||||||
char *amplifia = ECOMALLOC((len + 1) * sizeof(char),"Cannot allocate amplifia");
|
char *amplifia = ECOMALLOC((len + 1) * sizeof(char),"Cannot allocate amplifia");
|
||||||
char *seqc = &seq->SQ[start];
|
char *seqc = &seq->SQ[start];
|
||||||
|
|
||||||
strncpy(amplifia, seqc, len);
|
strncpy(amplifia, seqc, len);
|
||||||
return amplifia;
|
return amplifia;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
/*TR: Added*/
|
/*TR: Added*/
|
||||||
pairscount_t buildPrimerPairs(pecodnadb_t seqdb,uint32_t seqdbsize,pprimercount_t primers,poptions_t options)
|
ppairtree_t buildPrimerPairs(pecodnadb_t seqdb,uint32_t seqdbsize,pprimercount_t primers,poptions_t options)
|
||||||
{
|
{
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
uint32_t j;
|
uint32_t j;
|
||||||
@ -152,123 +160,131 @@ pairscount_t buildPrimerPairs(pecodnadb_t seqdb,uint32_t seqdbsize,pprimercount_
|
|||||||
uint32_t d;
|
uint32_t d;
|
||||||
uint32_t strt;
|
uint32_t strt;
|
||||||
uint32_t end;
|
uint32_t end;
|
||||||
uint32_t paircount = 0;
|
ppairtree_t primerpairs;
|
||||||
uint32_t pairslots = 500;
|
|
||||||
int32_t foundindex;
|
|
||||||
ppairs_t pairs;
|
|
||||||
pairscount_t primerpairs;
|
|
||||||
primermatchcount_t seqmatchcount;
|
primermatchcount_t seqmatchcount;
|
||||||
word_t w1;
|
word_t w1;
|
||||||
word_t w2;
|
word_t w2;
|
||||||
char *amplifia;
|
char *amplifia;
|
||||||
char *oldamp;
|
char *oldamp;
|
||||||
|
|
||||||
|
|
||||||
pairs = ECOMALLOC(pairslots * sizeof(pairs_t),"Cannot allocate pairs table");
|
|
||||||
|
primerpairs = initpairtree(NULL);
|
||||||
|
|
||||||
for (i=0; i < seqdbsize; i++)
|
for (i=0; i < seqdbsize; i++)
|
||||||
{
|
{
|
||||||
seqmatchcount = buildPrimerPairsForOneSeq(i, primers, options);
|
buildPrimerPairsForOneSeq(i, seqdb, primers, primerpairs, options);
|
||||||
if (seqmatchcount.matchcount == 0) continue;
|
|
||||||
|
|
||||||
for (j=0; j < seqmatchcount.matchcount; j++)
|
|
||||||
{
|
|
||||||
strt = 0;
|
|
||||||
w1 = seqmatchcount.matches[j].word;
|
|
||||||
/*first word should b on direct strand*/
|
|
||||||
if (!seqmatchcount.matches[j].strand)
|
|
||||||
w1 = ecoComplementWord(w1, options->primer_length);
|
|
||||||
else
|
|
||||||
strt = options->primer_length;
|
|
||||||
|
|
||||||
for (k=j+1; k < seqmatchcount.matchcount; k++)
|
|
||||||
{
|
|
||||||
end = 0;
|
|
||||||
w2 = seqmatchcount.matches[k].word;
|
|
||||||
/*second word should be on reverse strand*/
|
|
||||||
if (seqmatchcount.matches[k].strand)
|
|
||||||
w2 = ecoComplementWord(w2, options->primer_length);
|
|
||||||
else
|
|
||||||
end = options->primer_length;
|
|
||||||
|
|
||||||
if (!(seqmatchcount.matches[j].good || seqmatchcount.matches[k].good)) continue;
|
|
||||||
if (w1 == w2) continue;
|
|
||||||
|
|
||||||
d = seqmatchcount.matches[k].position - seqmatchcount.matches[j].position;
|
|
||||||
if (d >= options->lmin && d <= options->lmax)
|
|
||||||
{
|
|
||||||
/*get amplified string*/
|
|
||||||
amplifia = getamplifia (seqdb[i], seqmatchcount.matches[j].position + strt, d - strt - end);
|
|
||||||
|
|
||||||
foundindex = pairinlist(pairs, w1, w2, paircount);
|
|
||||||
if (foundindex != -1) /*pair is found*/
|
|
||||||
{
|
|
||||||
if (seqdb[i]->isexample)
|
|
||||||
pairs[foundindex].inexample++;
|
|
||||||
else
|
|
||||||
pairs[foundindex].outexample++;
|
|
||||||
|
|
||||||
if (pairs[foundindex].mind > d) pairs[foundindex].mind = d;
|
|
||||||
else if (pairs[foundindex].maxd < d) pairs[foundindex].maxd = d;
|
|
||||||
|
|
||||||
oldamp = addamplifiasetelem (&pairs[foundindex], amplifia, seqdb[i]->ranktaxonid);
|
|
||||||
/*if exact same string is already in amplifia set then use that for taxon set, it will help for
|
|
||||||
* calculating the fully identified taxons i.e specificity, we will compare pointrs instead of strings
|
|
||||||
* because same string means same pointer*/
|
|
||||||
if (oldamp)
|
|
||||||
{
|
|
||||||
ECOFREE (amplifia, "free amplifia");
|
|
||||||
amplifia = oldamp;
|
|
||||||
}
|
|
||||||
addtaxampsetelem (&pairs[foundindex], seqdb[i]->ranktaxonid, amplifia);
|
|
||||||
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (paircount == pairslots)
|
|
||||||
{
|
|
||||||
pairslots += 500;
|
|
||||||
pairs = ECOREALLOC(pairs, pairslots * sizeof(pairs_t), "Cannot allocate pairs table");
|
|
||||||
}
|
|
||||||
pairs[paircount].w1 = w1;
|
|
||||||
pairs[paircount].w2 = w2;
|
|
||||||
if (seqdb[i]->isexample) pairs[paircount].inexample = 1;
|
|
||||||
else pairs[paircount].outexample = 1;
|
|
||||||
pairs[paircount].mind = d;
|
|
||||||
pairs[paircount].maxd = d;
|
|
||||||
oldamp = addamplifiasetelem (&pairs[paircount], amplifia, seqdb[i]->ranktaxonid);
|
|
||||||
addtaxampsetelem (&pairs[paircount], seqdb[i]->ranktaxonid, amplifia);
|
|
||||||
|
|
||||||
paircount++;
|
|
||||||
}
|
|
||||||
else if (d > options->lmax)
|
|
||||||
break; /*once if the distance is greater than lmax then it will keep on increasing*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
ECOFREE(seqmatchcount.matches, "Cannot free matches table");
|
|
||||||
}
|
}
|
||||||
primerpairs.pairs = ECOREALLOC(pairs, paircount * sizeof(pairs_t), "Cannot allocate pairs table");
|
// if (seqmatchcount.matchcount == 0) continue;
|
||||||
primerpairs.paircount = paircount;
|
//
|
||||||
return primerpairs;
|
// for (j=0; j < seqmatchcount.matchcount; j++)
|
||||||
|
// {
|
||||||
|
// strt = 0;
|
||||||
|
// w1 = seqmatchcount.matches[j].word;
|
||||||
|
// /*first word should b on direct strand*/
|
||||||
|
// if (!seqmatchcount.matches[j].strand)
|
||||||
|
// w1 = ecoComplementWord(w1, options->primer_length);
|
||||||
|
// else
|
||||||
|
// strt = options->primer_length;
|
||||||
|
//
|
||||||
|
// for (k=j+1; k < seqmatchcount.matchcount; k++)
|
||||||
|
// {
|
||||||
|
// end = 0;
|
||||||
|
// w2 = seqmatchcount.matches[k].word;
|
||||||
|
// /*second word should be on reverse strand*/
|
||||||
|
// if (seqmatchcount.matches[k].strand)
|
||||||
|
// w2 = ecoComplementWord(w2, options->primer_length);
|
||||||
|
// else
|
||||||
|
// end = options->primer_length;
|
||||||
|
//
|
||||||
|
// if (!(seqmatchcount.matches[j].good || seqmatchcount.matches[k].good)) continue;
|
||||||
|
// if (w1 == w2) continue;
|
||||||
|
//
|
||||||
|
// d = seqmatchcount.matches[k].position - seqmatchcount.matches[j].position;
|
||||||
|
// if (d >= options->lmin && d <= options->lmax)
|
||||||
|
// {
|
||||||
|
// /*get amplified string*/
|
||||||
|
// amplifia = getamplifia (seqdb[i], seqmatchcount.matches[j].position + strt, d - strt - end);
|
||||||
|
//
|
||||||
|
// foundindex = pairinlist(pairs, w1, w2, paircount);
|
||||||
|
// if (foundindex != -1) /*pair is found*/
|
||||||
|
// {
|
||||||
|
// if (seqdb[i]->isexample)
|
||||||
|
// pairs[foundindex].inexample++;
|
||||||
|
// else
|
||||||
|
// pairs[foundindex].outexample++;
|
||||||
|
//
|
||||||
|
// if (pairs[foundindex].mind > d) pairs[foundindex].mind = d;
|
||||||
|
// else if (pairs[foundindex].maxd < d) pairs[foundindex].maxd = d;
|
||||||
|
//
|
||||||
|
// oldamp = addamplifiasetelem (&pairs[foundindex], amplifia, seqdb[i]->ranktaxonid);
|
||||||
|
// /*if exact same string is already in amplifia set then use that for taxon set, it will help for
|
||||||
|
// * calculating the fully identified taxons i.e specificity, we will compare pointrs instead of strings
|
||||||
|
// * because same string means same pointer*/
|
||||||
|
// if (oldamp)
|
||||||
|
// {
|
||||||
|
// ECOFREE (amplifia, "free amplifia");
|
||||||
|
// amplifia = oldamp;
|
||||||
|
// }
|
||||||
|
// addtaxampsetelem (&pairs[foundindex], seqdb[i]->ranktaxonid, amplifia);
|
||||||
|
//
|
||||||
|
// continue;
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// if (paircount == pairslots)
|
||||||
|
// {
|
||||||
|
// pairslots += 500;
|
||||||
|
// pairs = ECOREALLOC(pairs, pairslots * sizeof(pairs_t), "Cannot allocate pairs table");
|
||||||
|
// }
|
||||||
|
// pairs[paircount].w1 = w1;
|
||||||
|
// pairs[paircount].w2 = w2;
|
||||||
|
// if (seqdb[i]->isexample) pairs[paircount].inexample = 1;
|
||||||
|
// else pairs[paircount].outexample = 1;
|
||||||
|
// pairs[paircount].mind = d;
|
||||||
|
// pairs[paircount].maxd = d;
|
||||||
|
// oldamp = addamplifiasetelem (&pairs[paircount], amplifia, seqdb[i]->ranktaxonid);
|
||||||
|
// addtaxampsetelem (&pairs[paircount], seqdb[i]->ranktaxonid, amplifia);
|
||||||
|
//
|
||||||
|
// paircount++;
|
||||||
|
// }
|
||||||
|
// else if (d > options->lmax)
|
||||||
|
// break; /*once if the distance is greater than lmax then it will keep on increasing*/
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// ECOFREE(seqmatchcount.matches, "Cannot free matches table");
|
||||||
|
// }
|
||||||
|
// primerpairs.pairs = ECOREALLOC(pairs, paircount * sizeof(pairs_t), "Cannot allocate pairs table");
|
||||||
|
// primerpairs.paircount = paircount;
|
||||||
|
// return primerpairs;
|
||||||
}
|
}
|
||||||
|
|
||||||
primermatchcount_t buildPrimerPairsForOneSeq(uint32_t seqid,pprimercount_t primers,poptions_t options)
|
#define DMAX (2000000000)
|
||||||
{
|
|
||||||
uint32_t i,j,k;
|
static void buildPrimerPairsForOneSeq(uint32_t seqid,
|
||||||
uint32_t matchcount=0;
|
pecodnadb_t seqdb,
|
||||||
pprimermatch_t matches = NULL;
|
pprimercount_t primers,
|
||||||
primermatchcount_t seqmatchcount;
|
ppairtree_t pairs,
|
||||||
|
poptions_t options)
|
||||||
|
{
|
||||||
|
static uint32_t paircount=0;
|
||||||
|
uint32_t i,j,k;
|
||||||
|
uint32_t matchcount=0;
|
||||||
|
pprimermatch_t matches = NULL;
|
||||||
|
primermatchcount_t seqmatchcount;
|
||||||
|
ppair_t pcurrent;
|
||||||
|
pair_t current;
|
||||||
|
pprimer_t wswp;
|
||||||
|
bool_t bswp;
|
||||||
|
size_t distance;
|
||||||
|
|
||||||
seqmatchcount.matchcount = 0;
|
|
||||||
seqmatchcount.matches = NULL;
|
|
||||||
|
|
||||||
for (i=0;i < primers->size; i++)
|
for (i=0;i < primers->size; i++)
|
||||||
{
|
{
|
||||||
matchcount+=primers->primers[i].directCount[seqid];
|
matchcount+=primers->primers[i].directCount[seqid];
|
||||||
matchcount+=primers->primers[i].reverseCount[seqid];
|
matchcount+=primers->primers[i].reverseCount[seqid];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (matchcount <= 0) return seqmatchcount;
|
if (matchcount <= 0)
|
||||||
|
return;
|
||||||
|
|
||||||
matches = ECOMALLOC(matchcount * sizeof(primermatch_t),"Cannot allocate primers match table");
|
matches = ECOMALLOC(matchcount * sizeof(primermatch_t),"Cannot allocate primers match table");
|
||||||
|
|
||||||
for (i=0,j=0;i < primers->size; i++)
|
for (i=0,j=0;i < primers->size; i++)
|
||||||
@ -277,17 +293,15 @@ primermatchcount_t buildPrimerPairsForOneSeq(uint32_t seqid,pprimercount_t prime
|
|||||||
{
|
{
|
||||||
if (primers->primers[i].directCount[seqid]==1)
|
if (primers->primers[i].directCount[seqid]==1)
|
||||||
{
|
{
|
||||||
matches[j].word = primers->primers[i].word;
|
matches[j].primer = primers->primers+i;
|
||||||
matches[j].strand=TRUE;
|
matches[j].strand=TRUE;
|
||||||
matches[j].good=primers->primers[i].good;/*TR: Added*/
|
|
||||||
matches[j].position=primers->primers[i].directPos[seqid].value;
|
matches[j].position=primers->primers[i].directPos[seqid].value;
|
||||||
j++;
|
j++;
|
||||||
}
|
}
|
||||||
else for (k=0; k < primers->primers[i].directCount[seqid]; k++,j++)
|
else for (k=0; k < primers->primers[i].directCount[seqid]; k++,j++)
|
||||||
{
|
{
|
||||||
matches[j].word = primers->primers[i].word;
|
matches[j].primer = primers->primers+i;
|
||||||
matches[j].strand=TRUE;
|
matches[j].strand=TRUE;
|
||||||
matches[j].good=primers->primers[i].good;/*TR: Added*/
|
|
||||||
matches[j].position=primers->primers[i].directPos[seqid].pointer[k];
|
matches[j].position=primers->primers[i].directPos[seqid].pointer[k];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -296,26 +310,139 @@ primermatchcount_t buildPrimerPairsForOneSeq(uint32_t seqid,pprimercount_t prime
|
|||||||
{
|
{
|
||||||
if (primers->primers[i].reverseCount[seqid]==1)
|
if (primers->primers[i].reverseCount[seqid]==1)
|
||||||
{
|
{
|
||||||
matches[j].word = primers->primers[i].word;
|
matches[j].primer = primers->primers+i;
|
||||||
matches[j].strand=FALSE;
|
matches[j].strand=FALSE;
|
||||||
matches[j].good=primers->primers[i].good;/*TR: Added*/
|
|
||||||
matches[j].position=primers->primers[i].reversePos[seqid].value;
|
matches[j].position=primers->primers[i].reversePos[seqid].value;
|
||||||
j++;
|
j++;
|
||||||
}
|
}
|
||||||
else for (k=0; k < primers->primers[i].reverseCount[seqid]; k++,j++)
|
else for (k=0; k < primers->primers[i].reverseCount[seqid]; k++,j++)
|
||||||
{
|
{
|
||||||
matches[j].word = primers->primers[i].word;
|
matches[j].primer = primers->primers+i;
|
||||||
matches[j].strand=FALSE;
|
matches[j].strand=FALSE;
|
||||||
matches[j].good=primers->primers[i].good;/*TR: Added*/
|
|
||||||
matches[j].position=primers->primers[i].reversePos[seqid].pointer[k];
|
matches[j].position=primers->primers[i].reversePos[seqid].pointer[k];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sortmatch(matches,matchcount); // sort in asscending order by position
|
if (matchcount>1)
|
||||||
|
{
|
||||||
/*TR: Added*/
|
fprintf(stderr,"\n====================================\n");
|
||||||
seqmatchcount.matches = matches;
|
|
||||||
seqmatchcount.matchcount = matchcount;
|
sortmatch(matches,matchcount); // sort in ascending order by position
|
||||||
return seqmatchcount;
|
|
||||||
|
for (i=0; i < matchcount;i++)
|
||||||
|
{
|
||||||
|
// For all primers matching the sequence
|
||||||
|
|
||||||
|
for(j=i+1;
|
||||||
|
(j<matchcount)
|
||||||
|
&& ((distance=matches[j].position - matches[i].position - options->primer_length) < options->lmax);
|
||||||
|
j++
|
||||||
|
)
|
||||||
|
|
||||||
|
// For all not too far primers
|
||||||
|
|
||||||
|
if ( (matches[i].primer->good || matches[j].primer->good)
|
||||||
|
&& (distance > options->lmin)
|
||||||
|
)
|
||||||
|
{
|
||||||
|
|
||||||
|
// If possible primer pair
|
||||||
|
|
||||||
|
current.p1 = matches[i].primer;
|
||||||
|
current.asdirect1=matches[i].strand;
|
||||||
|
current.p2 = matches[j].primer;
|
||||||
|
current.asdirect2= !matches[j].strand;
|
||||||
|
current.maxd=DMAX;
|
||||||
|
current.mind=DMAX;
|
||||||
|
current.sumd=0;
|
||||||
|
current.inexample=0;
|
||||||
|
current.outexample=0;
|
||||||
|
|
||||||
|
|
||||||
|
// Standardize the pair
|
||||||
|
|
||||||
|
if (current.p2->word < current.p1->word)
|
||||||
|
{
|
||||||
|
wswp = current.p1;
|
||||||
|
current.p1=current.p2;
|
||||||
|
current.p2=wswp;
|
||||||
|
|
||||||
|
bswp = current.asdirect1;
|
||||||
|
current.asdirect1=current.asdirect2;
|
||||||
|
current.asdirect2=bswp;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Look for the new pair in already seen pairs
|
||||||
|
|
||||||
|
pcurrent = insertpair(current,pairs);
|
||||||
|
|
||||||
|
|
||||||
|
if (seqdb[seqid]->isexample)
|
||||||
|
|
||||||
|
{
|
||||||
|
pcurrent->inexample++;
|
||||||
|
pcurrent->sumd+=distance;
|
||||||
|
|
||||||
|
if (pcurrent->maxd=DMAX || distance > pcurrent->maxd)
|
||||||
|
pcurrent->maxd = distance;
|
||||||
|
|
||||||
|
if (distance < pcurrent->mind)
|
||||||
|
pcurrent->mind = distance;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
pcurrent->outexample++;
|
||||||
|
|
||||||
|
if ((pcurrent->outexample+pcurrent->inexample)==1)
|
||||||
|
{
|
||||||
|
paircount++;
|
||||||
|
pcurrent->pcr.ampslot=200;
|
||||||
|
pcurrent->pcr.ampcount=0;
|
||||||
|
pcurrent->pcr.amplifias = ECOMALLOC(sizeof(amplifia_t)*pcurrent->pcr.ampslot,
|
||||||
|
"Cannot allocate amplifia table");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (pcurrent->pcr.ampslot==pcurrent->pcr.ampcount)
|
||||||
|
{
|
||||||
|
pcurrent->pcr.ampslot+=200;
|
||||||
|
pcurrent->pcr.amplifias = ECOREALLOC(pcurrent->pcr.amplifias,
|
||||||
|
sizeof(amplifia_t)*pcurrent->pcr.ampslot,
|
||||||
|
"Cannot allocate amplifia table");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pcurrent->pcr.amplifias[pcr.ampcount].length=distance;
|
||||||
|
pcurrent->pcr.amplifias[pcr.ampcount].sequence=*(seqdb[seqid]);
|
||||||
|
// pcurrent->pcr.amplifias[pcr.ampcount].strand= ;
|
||||||
|
// pcurrent->pcr.amplifias[pcr.ampcount].amplifia= ;
|
||||||
|
|
||||||
|
pcurrent->pcr.ampcount++;
|
||||||
|
|
||||||
|
fprintf(stderr,"%c%c W1 : %s direct : %c",
|
||||||
|
"bG"[(int)pcurrent->p1->good],
|
||||||
|
"bG"[(int)pcurrent->p2->good],
|
||||||
|
ecoUnhashWord(pcurrent->p1->word, options->primer_length),
|
||||||
|
"><"[(int)pcurrent->asdirect1]
|
||||||
|
);
|
||||||
|
|
||||||
|
fprintf(stderr," W2 : %s direct : %c distance : %d (min/max/avg : %d/%d/%f) in/out: %d/%d %c (%d pairs)\n",
|
||||||
|
ecoUnhashWord(pcurrent->p2->word, options->primer_length),
|
||||||
|
"><"[(int)pcurrent->asdirect2],
|
||||||
|
distance,
|
||||||
|
pcurrent->mind,pcurrent->maxd,
|
||||||
|
(pcurrent->inexample) ? (float)pcurrent->sumd/pcurrent->inexample:0.0,
|
||||||
|
pcurrent->inexample,pcurrent->outexample,
|
||||||
|
" N"[(pcurrent->outexample+pcurrent->inexample)==1],
|
||||||
|
paircount
|
||||||
|
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
17
src/libecoprimer/pairtree.P
Normal file
17
src/libecoprimer/pairtree.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
pairtree.o pairtree.P : pairtree.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/search.h
|
133
src/libecoprimer/pairtree.c
Normal file
133
src/libecoprimer/pairtree.c
Normal file
@ -0,0 +1,133 @@
|
|||||||
|
/*
|
||||||
|
* pairtree.c
|
||||||
|
*
|
||||||
|
* Created on: 7 mars 2009
|
||||||
|
* Author: coissac
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "ecoprimer.h"
|
||||||
|
#include <search.h>
|
||||||
|
|
||||||
|
static void cleanpair(ppair_t pair);
|
||||||
|
static void deletepairlist(ppairlist_t list);
|
||||||
|
static int cmppair(const void* p1,const void*p2);
|
||||||
|
|
||||||
|
|
||||||
|
static void cleanamplifiatlist(pamplifiacount_t list)
|
||||||
|
{
|
||||||
|
if (list->amplifias)
|
||||||
|
ECOFREE(list->amplifias,
|
||||||
|
"Free amplifia list");
|
||||||
|
}
|
||||||
|
|
||||||
|
static void cleanpair(ppair_t pair)
|
||||||
|
{
|
||||||
|
cleanamplifiatlist(&(pair->pcr));
|
||||||
|
}
|
||||||
|
|
||||||
|
static ppairlist_t newpairlist(ppairlist_t parent, size_t size)
|
||||||
|
{
|
||||||
|
ppairlist_t tmp;
|
||||||
|
|
||||||
|
tmp=ECOMALLOC(sizeof(pairlist_t)+sizeof(pair_t)*(size-1),
|
||||||
|
"Cannot allocate new pair list");
|
||||||
|
|
||||||
|
tmp->pairslots=size;
|
||||||
|
tmp->paircount=0;
|
||||||
|
tmp->next=NULL;
|
||||||
|
|
||||||
|
if (parent)
|
||||||
|
parent->next=(void*)tmp;
|
||||||
|
|
||||||
|
return tmp;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void deletepairlist(ppairlist_t list)
|
||||||
|
{
|
||||||
|
size_t i;
|
||||||
|
|
||||||
|
if (list)
|
||||||
|
{
|
||||||
|
if (list->next)
|
||||||
|
{
|
||||||
|
deletepairlist(list->next);
|
||||||
|
list->next=NULL;
|
||||||
|
}
|
||||||
|
for (i=0; i < list->paircount; i++)
|
||||||
|
cleanpair((list->pairs)+i);
|
||||||
|
|
||||||
|
ECOFREE(list,"Delete pair list");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
static int cmppair(const void* p1,const void*p2)
|
||||||
|
{
|
||||||
|
ppair_t pr1,pr2;
|
||||||
|
|
||||||
|
pr1=(ppair_t)p1;
|
||||||
|
pr2=(ppair_t)p2;
|
||||||
|
|
||||||
|
if (pr1->p1 < pr2->p1) return -1;
|
||||||
|
if (pr1->p1 > pr2->p1) return 1;
|
||||||
|
|
||||||
|
if (pr1->asdirect1 < pr2->asdirect1) return -1;
|
||||||
|
if (pr1->asdirect1 > pr2->asdirect1) return 1;
|
||||||
|
|
||||||
|
if (pr1->p2 < pr2->p2) return -1;
|
||||||
|
if (pr1->p2 > pr2->p2) return 1;
|
||||||
|
|
||||||
|
if (pr1->asdirect2 < pr2->asdirect2) return -1;
|
||||||
|
if (pr1->asdirect2 > pr2->asdirect2) return 1;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
ppair_t pairintree (pair_t key,
|
||||||
|
ppairtree_t pairlist)
|
||||||
|
{
|
||||||
|
if (!pairlist->tree)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
return *((ppair_t*)tsearch((const void *)(&key),
|
||||||
|
&(pairlist->tree),
|
||||||
|
cmppair
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
ppair_t insertpair(pair_t key,
|
||||||
|
ppairtree_t list)
|
||||||
|
{
|
||||||
|
ppair_t current;
|
||||||
|
ppair_t found;
|
||||||
|
|
||||||
|
if (list->last->paircount==list->last->pairslots)
|
||||||
|
{
|
||||||
|
list->last->next=newpairlist(list,100);
|
||||||
|
list->last=list->last->next;
|
||||||
|
}
|
||||||
|
|
||||||
|
current = list->last->pairs + list->last->paircount;
|
||||||
|
*current=key;
|
||||||
|
|
||||||
|
found = *((ppair_t*)tsearch((const void *)current,
|
||||||
|
&(list->tree),
|
||||||
|
cmppair));
|
||||||
|
if (found==current)
|
||||||
|
list->last->paircount++;
|
||||||
|
|
||||||
|
return found;
|
||||||
|
}
|
||||||
|
|
||||||
|
ppairtree_t initpairtree(ppairtree_t tree)
|
||||||
|
{
|
||||||
|
fprintf(stderr,"coucou from initpairtree\n");
|
||||||
|
|
||||||
|
if (!tree)
|
||||||
|
tree = ECOMALLOC(sizeof(pairtree_t),"Cannot allocate pair tree");
|
||||||
|
|
||||||
|
tree->first=newpairlist(NULL,500);
|
||||||
|
tree->last=tree->first;
|
||||||
|
|
||||||
|
tree->tree=NULL;
|
||||||
|
}
|
17
src/libecoprimer/queue.P
Normal file
17
src/libecoprimer/queue.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
queue.o queue.P : queue.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h
|
17
src/libecoprimer/readdnadb.P
Normal file
17
src/libecoprimer/readdnadb.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
readdnadb.o readdnadb.P : readdnadb.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h
|
10
src/libecoprimer/smothsort.P
Normal file
10
src/libecoprimer/smothsort.P
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
smothsort.o smothsort.P : smothsort.c /usr/include/assert.h /usr/include/sys/cdefs.h \
|
||||||
|
/usr/include/stdio.h /usr/include/_types.h /usr/include/sys/_types.h \
|
||||||
|
/usr/include/machine/_types.h /usr/include/i386/_types.h \
|
||||||
|
/usr/include/sys/types.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/machine/endian.h /usr/include/i386/endian.h \
|
||||||
|
/usr/include/sys/_endian.h /usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/inttypes.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h
|
17
src/libecoprimer/sortmatch.P
Normal file
17
src/libecoprimer/sortmatch.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
sortmatch.o sortmatch.P : sortmatch.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/math.h /usr/include/architecture/i386/math.h
|
17
src/libecoprimer/sortword.P
Normal file
17
src/libecoprimer/sortword.P
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
sortword.o sortword.P : sortword.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/math.h /usr/include/architecture/i386/math.h
|
18
src/libecoprimer/strictprimers.P
Normal file
18
src/libecoprimer/strictprimers.P
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
strictprimers.o strictprimers.P : strictprimers.c ecoprimer.h /usr/include/inttypes.h \
|
||||||
|
/usr/include/sys/cdefs.h /usr/include/_types.h \
|
||||||
|
/usr/include/sys/_types.h /usr/include/machine/_types.h \
|
||||||
|
/usr/include/i386/_types.h \
|
||||||
|
/usr/lib/gcc/i686-apple-darwin9/4.0.1/include/stdint.h \
|
||||||
|
/usr/include/stdlib.h /usr/include/available.h /usr/include/sys/wait.h \
|
||||||
|
/usr/include/sys/signal.h /usr/include/sys/appleapiopts.h \
|
||||||
|
/usr/include/machine/signal.h /usr/include/i386/signal.h \
|
||||||
|
/usr/include/i386/_structs.h /usr/include/sys/_structs.h \
|
||||||
|
/usr/include/machine/_structs.h /usr/include/mach/i386/_structs.h \
|
||||||
|
/usr/include/sys/resource.h /usr/include/machine/endian.h \
|
||||||
|
/usr/include/i386/endian.h /usr/include/sys/_endian.h \
|
||||||
|
/usr/include/libkern/_OSByteOrder.h \
|
||||||
|
/usr/include/libkern/i386/_OSByteOrder.h /usr/include/alloca.h \
|
||||||
|
/usr/include/machine/types.h /usr/include/i386/types.h \
|
||||||
|
/usr/include/stdio.h ecotype.h ../libecoPCR/ecoPCR.h apat.h libstki.h \
|
||||||
|
debug.h /usr/include/string.h /usr/include/math.h \
|
||||||
|
/usr/include/architecture/i386/math.h
|
Reference in New Issue
Block a user