title: R table() labels
body: <p>I have 30 columns of qualitative data which I want to transform in quantitative data. </p>
  
  <p>Firstly I want to find out what values are stored in each column and then replace each instance of this value with a number.  I can use either table() or summary() to get a frequency table for each data value but then I am unable to access these values - I can only get the frequencies which I don't care about.  I have also looked at unique() and duplicated() to no avail.</p>
  
  <p>For example for the first column I have 10,000 rows containing either "dummy1", "dummy2", "dummy3", "dummy4" or "dummy5".  I want to replace these values with 1, 2, 3, 4 or 5 respectively.</p>
  
  <p>table(data) gives me a summary of the frequency for each qualitative value but I'm unable to isolate the values "dummy1" etc in a variable (which I will later match to replace).  Because I have 30 columns of data I don't want to hard code these dummy values.  Unique() only gives the unique value but I want a list of each possible value.</p>
  
  <p>Any help would be much appreicated. </p>