Class: TCGA::RsemExpression
- Inherits:
- 
      Object
      
        - Object
- TCGA::RsemExpression
 
- Defined in:
- lib/tcga.rb
Instance Method Summary collapse
- #gene_exp ⇒ Object
- #gene_file ⇒ Object
- 
  
    
      #initialize(sample)  ⇒ RsemExpression 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of RsemExpression. 
- #sdrf ⇒ Object
Constructor Details
#initialize(sample) ⇒ RsemExpression
Returns a new instance of RsemExpression.
| 16 17 18 | # File 'lib/tcga.rb', line 16 def initialize sample @sample = sample end | 
Instance Method Details
#gene_exp ⇒ Object
| 25 26 27 28 29 30 31 32 33 34 | # File 'lib/tcga.rb', line 25 def gene_exp if gene_file @gene_exp ||= HashTable.new gene_file, :header => { :gene_id => :str, :raw_count => :float, :scaled_estimate => :float, :transcript_id => :str }, :skip_header => true, :idx => :gene_id end end | 
#gene_file ⇒ Object
| 19 20 21 22 23 24 | # File 'lib/tcga.rb', line 19 def gene_file exp = sdrf.find do |exp| exp. == @sample. && exp.header21 == 'RSEM_genes' end File.join(GermConfig.get_conf(:tcga, :cancer_types, @sample.cancer_type, :rsem_exp_raw), exp.header19) if exp end | 
#sdrf ⇒ Object
| 35 36 37 38 39 | # File 'lib/tcga.rb', line 35 def sdrf return @sdrf if @sdrf sdrf_file = GermConfig.get_conf(:tcga, :cancer_types, @sample.cancer_type, :rsem_exp_sdrf) @sdrf = SDRF.new sdrf_file if sdrf_file end |