interval_overlap       package:genomeIntervals       R Documentation

_A_s_s_e_s_s _o_v_e_r_l_a_p _f_r_o_m _o_n_e _s_e_t _o_f _g_e_n_o_m_i_c _i_n_t_e_r_v_a_l_s _t_o _a_n_o_t_h_e_r

_D_e_s_c_r_i_p_t_i_o_n:

     Given two objects, a 'from' and a 'to', assess which intervals in
     'to' overlap which of 'from'.

_U_s_a_g_e:

     ## S4 method for signature 'Genome_intervals,
     ##   Genome_intervals':
     interval_overlap(
                      from, to,
                      check_valid = TRUE
                      )
     ## S4 method for signature 'Genome_intervals_stranded,
     ##   Genome_intervals_stranded':
     interval_overlap(
                      from, to,
                      check_valid = TRUE
                      )

_A_r_g_u_m_e_n_t_s:

    from: A 'Genome_intervals' or 'Genome_intervals_stranded' object. 

      to: A 'Genome_intervals' or 'Genome_intervals_stranded' object.

check\_valid: Should 'validObject' be called before passing to compiled
          code? 

_D_e_t_a_i_l_s:

     A wrapper calling 'intervals:interval_overlap' by 'seq_name' and
     by 'strand' (if both 'to' and 'from' are
     '"Genome_intervals_stranded"' objects).

_V_a_l_u_e:

     A list, with one element for each row of 'from'. The elements are
     vectors of indices, indicating which 'to' rows overlap each from.
     A list element of length 0 indicates a from with no overlapping to
     intervals.

_E_x_a_m_p_l_e_s:

     data(gen_ints)   
     # i as entered
     i

     # i in close_intervals notation
     close_intervals(i)
      
     # j in close_intervals notation
     close_intervals(j)
      
     # list of intervals of j overlapping intervals of i
     interval_overlap(i,j)
              

