git-svn-id: https://www.grenoble.prabi.fr/svn/LECASofts/ecoPrimers/trunk@256 60f365c0-8329-0410-b2a4-ec073aeeaa1d
This commit is contained in:
@@ -26,7 +26,7 @@ word_t extractSite(char* sequence, size_t begin, size_t length, bool_t strand)
|
||||
return site;
|
||||
}
|
||||
|
||||
void getThermoProperties (ppair_t* pairs, size_t count, poptions_t options)
|
||||
/*void getThermoProperties (ppair_t* pairs, size_t count, poptions_t options)
|
||||
{
|
||||
size_t i, j,k,l;
|
||||
uint32_t bp1,bp2;
|
||||
@@ -112,4 +112,71 @@ void getThermoProperties (ppair_t* pairs, size_t count, poptions_t options)
|
||||
}
|
||||
|
||||
}
|
||||
}*/
|
||||
|
||||
void getProbeThermoProperties (pecodnadb_t seqdb,uint32_t seqdbsize, pprobecount_t pprobs, poptions_t options)
|
||||
{
|
||||
size_t i, j,k;
|
||||
uint32_t bp1,bp2;
|
||||
word_t w;
|
||||
//word_t wtmp;
|
||||
bool_t strand;
|
||||
|
||||
char *sq;
|
||||
char prmr[50];
|
||||
|
||||
float mtemp;
|
||||
|
||||
for (i = 0; i < pprobs->size; i++)
|
||||
{
|
||||
w = pprobs->probes[i].primer->word;
|
||||
//wtmp = ecoComplementWord(w1,options->primer_length);
|
||||
//if (wtmp > w) w = wtmp;
|
||||
|
||||
strncpy(prmr,ecoUnhashWord(w, options->primer_length),options->primer_length);
|
||||
prmr[options->primer_length]=0;
|
||||
|
||||
pprobs->probes[i].ptemp = nparam_CalcSelfTM (options->pnparm, prmr, options->primer_length) - 273.0;
|
||||
|
||||
pprobs->probes[i].pmintemp = 100;
|
||||
|
||||
for (j = 0; j < seqdbsize; j++)
|
||||
{
|
||||
if (!seqdb[j]->isexample) continue;
|
||||
sq = seqdb[j]->SQ;
|
||||
|
||||
|
||||
if (pprobs->probes[i].primer->directCount[j] > 0)
|
||||
{
|
||||
strand = TRUE;
|
||||
for (k = 0; k < pprobs->probes[i].primer->directCount[j]; k++)
|
||||
{
|
||||
bp1 = (pprobs->probes[i].primer->directCount[j] > 1)? pprobs->probes[i].primer->directPos[j].pointer[k] : pprobs->probes[i].primer->directPos[j].value;
|
||||
mtemp = nparam_CalcTwoTM(options->pnparm,
|
||||
prmr,
|
||||
ecoUnhashWord(extractSite(sq,bp1,options->primer_length,strand),options->primer_length),
|
||||
options->primer_length) - 273.0;
|
||||
|
||||
if (mtemp < pprobs->probes[i].pmintemp)
|
||||
pprobs->probes[i].pmintemp = mtemp;
|
||||
}
|
||||
}
|
||||
|
||||
if (pprobs->probes[i].primer->reverseCount[j] > 0)
|
||||
{
|
||||
strand = FALSE;
|
||||
for (k = 0; k < pprobs->probes[i].primer->directCount[j]; k++)
|
||||
{
|
||||
bp1 = (pprobs->probes[i].primer->reverseCount[j] > 1)? pprobs->probes[i].primer->reversePos[j].pointer[k] : pprobs->probes[i].primer->reversePos[j].value;
|
||||
mtemp = nparam_CalcTwoTM(options->pnparm,
|
||||
prmr,
|
||||
ecoUnhashWord(extractSite(sq,bp1,options->primer_length,strand),options->primer_length),
|
||||
options->primer_length) - 273.0;
|
||||
|
||||
if (mtemp < pprobs->probes[i].pmintemp)
|
||||
pprobs->probes[i].pmintemp = mtemp;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -1,9 +1,10 @@
|
||||
#ifndef THERMOSTATS_H_
|
||||
#define THERMOSTATS_H_
|
||||
|
||||
#include "../libecoprimer/ecoprimer.h"
|
||||
#include "../libecoprobe/ecoprobe.h"
|
||||
|
||||
void getThermoProperties (ppair_t* pairs, size_t count, poptions_t options);
|
||||
//void getThermoProperties (ppair_t* pairs, size_t count, poptions_t options);
|
||||
word_t extractSite(char* sequence, size_t begin, size_t length, bool_t strand);
|
||||
void getProbeThermoProperties (pecodnadb_t seqdb,uint32_t seqdbsize, pprobecount_t pprobs, poptions_t options);
|
||||
|
||||
#endif
|
Reference in New Issue
Block a user