title: Array filter vs. Core Data pull performance
body: <p>I'm wondering about the performance differences between two different methods of data filtering. Here's what I'm working with:</p>
  
  <ul>
  <li>A set of core data objects</li>
  <li>A UISegmentedControl that represents a boolean filter (learned vs. not learned)</li>
  <li>A UITableView that displays the filtered data set</li>
  </ul>
  
  <p>As I see it, there are two possible approaches here:</p>
  
  <ol>
  <li>Pull the entire core data set in viewDidLoad. Filter the array of data using a predicate when the segmented control value changes. Reload the tableview.</li>
  <li>Initially pull the core data set with a predicate. When the segmented control value changes, re-pull the core data set with the updated predicate. Reload the tableview.</li>
  </ol>
  
  <p>I know there are factors that influence the answer (how large the data set is, how often the segmented control will be used), I'm just wondering if there is an overall best practice between the two.</p>