title: Using uipickerview to change variable
body: <p>I am new to Xcode and I'm stuck trying to assign number values to my UIPickerView rows.
  What I would like to achieve is in my mind a simple task but I can't do it.
  I have a picker with the words "weekly", "Fortnightly", "Monthly", "Annual".
  I want each chosen word to be represented by a number hidden in my code.
  My first thought was to alter the value of an integer based on the .text in the label my picker changes. e.g.</p>
  
  <pre><code> /* double z = {(if payCycleLbl.text isEqual: @"Weekly"){
          double z = [[NSString alloc] initWithFormat:@"%f", 52];}
          (else if payCycleLbl.text isEqual: @"Fortnightly"){
              double z = [[NSString alloc] initWithFormat:@"%f", 26];}
          (else if payCycleLbl.text isEqual: @"Monthly"){
              double z = [[NSString alloc] initWithFormat:@"%f", 12];}
          (else if payCycleLbl.text isEqual: @"Annually"){
              double z = [[NSString alloc] initWithFormat:@"%f",1};}
                         } */    
  </code></pre>
  
  <p>Im open to any approach as long as it keeps in mind the goal here is to allocate a number that changes based on the users selection, and can be used in other calculations throughout my script represented by a single 'double z' value. </p>
  
  <p>Thank you for you suggestions.</p>