title: Why does {{ isNan(x) }} not work in angularJS?
body: <p>Note the title of this question has changed to one that's more focused to the exact problem. See the comment stream to follow how it came about that I realized the problem is that AngularJS does not seem to handle {{ isNaN() }} </p>
  
  <p>I have the following in my HTML:</p>
  
  <pre><code>xx {{ option.selectedSubject }} yy {{ (option.selectedSubject == null) }} zz
  </code></pre>
  
  <p>and I also tried:</p>
  
  <pre><code>xx {{ option.selectedSubject }} yy {{ option.selectedSubject == null }} z
  </code></pre>
  
  <p>and:</p>
  
  <pre><code>xx {{ option.selectedSubject }} yy {{ option.selectedSubject === null }} zz
  </code></pre>
  
  <p>Can someone help explain to me why I get the following for each of the above when I view my page:</p>
  
  <pre><code>xx null yy false zz
  </code></pre>
  
  <p><strong>Update 1</strong> I tried the following:</p>
  
  <pre><code>aa {{ option.selectedSubject === "null" }} bb {{ option.selectedSubject == "null" }} cc
  </code></pre>
  
  <p>and it gives this:</p>
  
  <pre><code>aa false bb false cc
  </code></pre>
  
  <p><strong>Update 2</strong> I am not sure if this helps but here's what populates the values of option.selectedSubject. In this case there's nothing in local storage:</p>
  
  <pre><code>$scope.option.selectedSubject = parseInt(localStorage.get('selectedSubject'));
  </code></pre>
  
  <p>When I check the value of $scope.option.selectedSubject it is <strong>NaN</strong> </p>