예제 #1
0
 public FKPM(double fkpm, double hi, double lo, BioSample samp)
 {
     Sample    = samp;
     FKPMCount = fkpm;
     HI        = hi;
     LO        = lo;
 }
예제 #2
0
        protected static void SendToStaticFKPM(PreSampleDefinition p, BioSample bios)
        {
            bios.HasExprs = true;
            if (LatestFKPMColIndexed == null)
            {
                LatestFKPMColIndexed = new Dictionary <string, BioSample[]> ();
            }

            foreach (string st in p.FileNames)
            {
                if (!LatestFKPMColIndexed.ContainsKey(st))
                {
                    LatestFKPMColIndexed.Add(st, new BioSample[p.TotalColumns]);
                }
                foreach (int ii in p.ColIDs)
                {
                    int index = ii - 9;

                    if (index != 0)
                    {
                        index /= 4;
                    }

                    LatestFKPMColIndexed [st] [index] = bios;
                }
            }
            hasFKPMSomethingToLoad = true;
        }
예제 #3
0
 public static void Assemble()
 {
     Genome = new Genome();
     ProgramState.Init();
     AppSettings.Assemble();
     RankSplit.Assemble();
     FPKMFileNames    = new List <string> ();
     BAMFileNames     = new List <string> ();
     VariantFileNames = new List <string> ();
     TypeDict         = new ElementTypeDictionary();
     Samples          = new Dictionary <string, BioSample> ();
     BioSample.ResetStaticLoader();
     GeneToScaffDict   = new Dictionary <string, string> ();
     RegionToScaffDict = new Dictionary <string, string> ();
     RSPToMergeSeries  = new List <Series> ();
     StatsTester.Assemble();
 }
예제 #4
0
        private static void RunSampleAllocationLoading(object ob)
        {
            try
            {
                BioSample.ResetStaticLoader();
                List <PreSampleDefinition> prel = (List <PreSampleDefinition>)ob;

                foreach (PreSampleDefinition pre in prel)
                {
                    if (!Samples.ContainsKey(pre.ID))
                    {
                        Samples.Add(pre.ID, new BioSample(pre.ID));
                    }
                    Samples [pre.ID].RecieveDefinition(pre);
                }

                BioSample.LoadAllStatic();
            }
            catch (Exception e) {
                ShowMessageWindow(e.Message, true);
            }
        }
예제 #5
0
 protected static void SendToStatic(PreSampleDefinition p, BioSample bios)
 {
     bios.HasVars = true;
     if (LatestVarColIndexed == null)
     {
         LatestVarColIndexed = new Dictionary <string, BioSample[]> ();
     }
     if (IsGenotypedNames == null)
     {
         IsGenotypedNames = new Dictionary <string, bool> ();
     }
     if (p.IsGenotyped)
     {
         if (!LatestVarColIndexed.ContainsKey(p.FileNames [0]))
         {
             LatestVarColIndexed.Add(p.FileNames [0], new BioSample[p.TotalColumns]);
         }
         foreach (int ii in p.ColIDs)
         {
             LatestVarColIndexed [p.FileNames [0]] [ii - 9] = bios;
         }
         if (!IsGenotypedNames.ContainsKey(p.FileNames [0]))
         {
             IsGenotypedNames.Add(p.FileNames [0], p.IsGenotyped);
         }
     }
     else
     {
         foreach (string s in p.FileNames)
         {
             if (!IsGenotypedNames.ContainsKey(s))
             {
                 IsGenotypedNames.Add(s, p.IsGenotyped);
             }
         }
     }
     hasVarSomethingToLoad = true;
 }
예제 #6
0
 public NameRead(BioSample samp, int _start, int _end, string name)
     : base(samp, _start, _end)
 {
     Name = name;
 }
예제 #7
0
 public NameRead(BioSample samp, string name) : base(samp)
 {
     Name = name;
 }
예제 #8
0
 public SeqRead(BioSample samp, int _start, int _end)
 {
     Sample = samp;
     Start  = _start;
     End    = _end;
 }
예제 #9
0
 public SeqRead(BioSample samp)
 {
     Sample = samp;
 }
예제 #10
0
 public SampleVariant(int ma, int alt, BioSample bio)
 {
     MajorInd = ma;
     AltInd   = alt;
     BioS     = bio;
 }