#include "common.h"#include "snof.h"#include "dnautil.h"#include "dnaseq.h"#include "fa.h"#include "nt4.h"#include "cda.h"#include "wormdna.h"#include "flydna.h"Include dependency graph for flydna.c:

Go to the source code of this file.
Functions | |
| void | flyLoadNt4Genome (struct nt4Seq ***retNt4Seq, int *retNt4Count) |
| void | flyFreeNt4Genome (struct nt4Seq ***pNt4Seq) |
| void | flyChromNames (char ***retNames, int *retNameCount) |
| void | flyFaCommentIntoInfo (char *faComment, struct wormCdnaInfo *retInfo) |
| boolean | flyCdnaSeq (char *name, struct dnaSeq **retDna, struct wormCdnaInfo *retInfo) |
| char * | flyFeaturesDir () |
| FILE * | flyOpenGoodAli () |
Variables | |
| static char const | rcsid [] = "$Id: flydna.c,v 1.4 2003/05/06 07:33:42 kate Exp $" |
| static char * | chromNames [] = {"adh"} |
| static char * | ntFileNames [] = {"c:/biodata/fly/chrom/adh.nt"} |
| boolean flyCdnaSeq | ( | char * | name, | |
| struct dnaSeq ** | retDna, | |||
| struct wormCdnaInfo * | retInfo | |||
| ) |
Definition at line 77 of file flydna.c.
References cdnaFa, cdnaSnof, FALSE, faReadNext(), flyFaCommentIntoInfo(), mustOpen(), SEEK_SET, snofFindOffset(), snofMustOpen(), and TRUE.
00080 { 00081 long offset; 00082 char *faComment; 00083 char **pFaComment = (retInfo == NULL ? NULL : &faComment); 00084 static struct snof *cdnaSnof = NULL; 00085 static FILE *cdnaFa; 00086 00087 if (cdnaSnof == NULL) 00088 cdnaSnof = snofMustOpen("c:/biodata/fly/cDna/allcdna"); 00089 if (cdnaFa == NULL) 00090 cdnaFa = mustOpen("c:/biodata/fly/cDna/allcdna.fa", "rb"); 00091 if (!snofFindOffset(cdnaSnof, name, &offset)) 00092 return FALSE; 00093 fseek(cdnaFa, offset, SEEK_SET); 00094 if (!faReadNext(cdnaFa, name, TRUE, pFaComment, retDna)) 00095 return FALSE; 00096 flyFaCommentIntoInfo(faComment, retInfo); 00097 return TRUE; 00098 }
Here is the call graph for this function:

| void flyChromNames | ( | char *** | retNames, | |
| int * | retNameCount | |||
| ) |
Definition at line 48 of file flydna.c.
References ArraySize, and chromNames.
00050 { 00051 *retNames = chromNames; 00052 *retNameCount = ArraySize(chromNames); 00053 }
| void flyFaCommentIntoInfo | ( | char * | faComment, | |
| struct wormCdnaInfo * | retInfo | |||
| ) |
Definition at line 55 of file flydna.c.
References zeroBytes().
Referenced by flyCdnaSeq().
00058 { 00059 if (retInfo) 00060 { 00061 char *s; 00062 zeroBytes(retInfo, sizeof(*retInfo)); 00063 /* Separate out first word and use it as name. */ 00064 s = strchr(faComment, ' '); 00065 if (s != NULL) 00066 *s++ = 0; 00067 retInfo->name = faComment+1; 00068 retInfo->motherString = faComment; 00069 s = strrchr(retInfo->name, '.'); 00070 retInfo->orientation = '+'; 00071 if (s != NULL) 00072 retInfo->orientation = (s[1] == '3' ? '-' : '+'); 00073 } 00074 }
Here is the call graph for this function:

Here is the caller graph for this function:

| char* flyFeaturesDir | ( | ) |
| void flyFreeNt4Genome | ( | struct nt4Seq *** | pNt4Seq | ) |
Definition at line 35 of file flydna.c.
References ArraySize, freeNt4(), freez(), and ntFileNames.
00037 { 00038 struct nt4Seq **pSeq; 00039 int i; 00040 00041 if ((pSeq = *pNt4Seq) == NULL) 00042 return; 00043 for (i=0; i<ArraySize(ntFileNames); ++i) 00044 freeNt4(&pSeq[i]); 00045 freez(pNt4Seq); 00046 }
Here is the call graph for this function:

| void flyLoadNt4Genome | ( | struct nt4Seq *** | retNt4Seq, | |
| int * | retNt4Count | |||
| ) |
Definition at line 20 of file flydna.c.
References ArraySize, chromNames, loadNt4(), needMem(), and ntFileNames.
00022 { 00023 struct nt4Seq **pSeq; 00024 int i; 00025 00026 pSeq = needMem(ArraySize(ntFileNames) * sizeof(pSeq[0]) ); 00027 for (i=0; i<ArraySize(ntFileNames); ++i) 00028 { 00029 pSeq[i] = loadNt4(ntFileNames[i], chromNames[i]); 00030 } 00031 *retNt4Seq = pSeq; 00032 *retNt4Count = ArraySize(ntFileNames); 00033 }
Here is the call graph for this function:

| FILE* flyOpenGoodAli | ( | ) |
Definition at line 107 of file flydna.c.
References cdaOpenVerify().
00110 { 00111 return cdaOpenVerify("C:/biodata/fly/cDNA/good.ali"); 00112 }
Here is the call graph for this function:

char* chromNames[] = {"adh"} [static] |
Definition at line 17 of file flydna.c.
Referenced by flyChromNames(), flyLoadNt4Genome(), and xenAlignWorm().
char* ntFileNames[] = {"c:/biodata/fly/chrom/adh.nt"} [static] |
char const rcsid[] = "$Id: flydna.c,v 1.4 2003/05/06 07:33:42 kate Exp $" [static] |
1.5.2