title: Filter an object containing multiple lists on a common field c#
body: <p>I am trying to find if there is some quick way to filter an object that has multiple list elements on a common field. Example, if I have vital height and weight lists in vital class, I want to filter the vital object to return the data in the list filtered by <code>EntryDate</code>.</p>
  
  <pre><code>public class VitalHeight
  {
    public int Id { get; set; }
    public string Value { get; set; }
    public string EnterDate { get; set; }
  }
  
  public class VitalWeight
  {
    public int Id { get; set; }
    public string Value { get; set; }
    public string EnterDate { get; set; }
  }
  
  public class Vital
  {
    public double PaientId { get; set; }
    public List&lt;VitalWeight&gt; Weights { get; set; }
    public List&lt;VitalHeight&gt; Heights { get; set; }
  }
  
  Vital vitals = controller.GetAllVitals(1234); // Get vitals by patient id
  </code></pre>
  
  <p>Is there an easy way to filter the vitals that I got from <code>GetAllVitals()</code> by <code>EntryDate</code>?</p>
  
  <p>I have data in <code>vitals</code> object something like:</p>
  
  <pre><code>PatientId: 1234
  Weights: {[Id: 1, Value: 290, EntryDate: 1/31/2017 12:34:00 PM], 
            [Id: 2, Value: 291, EntryDate: 1/31/2017 2:14:00 PM]}
  Heights: {[Id: 1, Value: 5.7, EntryDate: 1/31/2017 12:34:00 PM]}
  </code></pre>
  
  <p>So, the output for <code>EntryDate="1/31/2017 12:34:00 PM"</code> should be:</p>
  
  <pre><code>PatientId: 1234
  Weights: {[Id: 1, Value: 290, EntryDate: 1/31/2017 12:34:00 PM]}
  Heights: {[Id: 1, Value: 5.7, EntryDate: 1/31/2017 12:34:00 PM]}
  </code></pre>
  
  <p>There are more list of vital signs in vital object which has similar structure and I need to filter on <code>EntryDate</code>.</p>
  
  <p>I was trying to do this using linq, but didn't quite get it. </p>