lecture19_slides - Overview of today Today Review of...

Info icon This preview shows pages 1–13. Sign up to view the full content.

View Full Document Right Arrow Icon
Overview of today Today: Review of concepts from last time Statistics for differential expression analysis Formatted printing Reading from and writing to files in Matlab Start on visualizing data in Matlab Next week: - More visualizing data in Matlab - Methods for clustering gene expression data
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Conditions for matrices What if we are comparing matrices or vectors? Recall, the following are for scalars: a==b, a > b, a < b, a >= b, a <= b, a ~= b 0 1 0 0 0 1 1 0 0 1 2 5 1 2 6 u v == ? If you want to see if two matrices are identical, use the more general function isequal : >> isequal(u,v) ans = 0 >> v(1) = 1; v(3) = 5; isequal(u,v) ans = 1 conditionals.m
Image of page 2
Multiple Conditions Expressing multiple conditions condition1 AND condition2: (a < b) & (c ~= d) condition1 OR condition2: (a < b) | (c ~= d) NOT condition1: ~ (a < b) To avoid ambiguity, it helps to use parentheses to group conditions, e.g. (condition1 AND ( (NOT condition2) OR condition3) ) Just like single conditions, multiple conditions can be stored to a variable: Recall that Perl uses double symbols for “and” and “or”: “&&”, “||”. Matlab gives you the option of using single or double symbols. They mean slightly different things, which we will not explore here. is_n_bw_4_and_7 = 0 is_m_bw_4_and_7 = 1 conditionals.m
Image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Example with multiple conditions conditionals.m w = 1 4 25 Recall that both u and v are column vectors of length 3. 1 2 5 u = 1 2 5 v =
Image of page 4