title: Counting number of positive and negative values group by some column mysql query
body: <p>I have following layout of a mysql table:</p>
  
  <pre><code>+------+-------+-----+------+
  | user |subject|month|change|
  +------+-------+-----+------+
  |Donald| Math  | Jan | 3.15 |
  +------+-------+-----+------+
  | Mike | Math  | Jan | 2.15 |
  +------+-------+-----+------+
  |Regan | Math  | Jan | 3.00 |
  +------+-------+-----+------+
  |Donald| Engl  | Febr|-3.05 |
  +------+-------+-----+------+
  | Mike | Engl  | Febr| 3.00 |
  +------+-------+-----+------+
  |Regan | Engl  | Febr|-3.00 |
  +------+-------+-----+------+
  |Donald| Geog  | Jan | 3.00 |
  +------+-------+-----+------+
  | Mike | Geog  | Jan |-2.15 |
  +------+-------+-----+------+
  |Regan | Geog  | Jan | 3.60 |
  +------+-------+-----+------+
  </code></pre>
  
  <p>I have to count positive or negative change group by subject, at the same time get the name of the group. If I query the mysql table like this:</p>
  
  <pre><code>COUNT (*) FROM $table WHERE change&gt;0 GROUP BY subject
  </code></pre>
  
  <p>It will only count the number of positive change (>0) group by subject column. It is not possible to get number of negative change (&lt;0) and to get the group name (Math, Eng &amp; Geog).</p>
  
  <p>I want the result should be like that:</p>
  
  <pre><code>===============
  Group | &gt;0| &lt;0|
  ===============
   Math | 3 | 0 | 
  ---------------
   Eng  | 1 | 2 |
  ---------------
   Geog | 2 | 1 |
  ---------------
  </code></pre>
  
  <p>What would be single mysql query in order to get the result like above?</p>