Skip to main content
added 66 characters in body
Source Link
Chris Degnen
  • 31.3k
  • 2
  • 56
  • 109
sample = {{"September 29", "2.2300"},
   {"September 30", "2.2075"},
   {"October 1", "2.1825"},
   {"October 2", "2.1400"},
   {"October 3", "2.1500"},
   {"Sep 29 - Oct 3", "2.1820-AVG"},
   {"October 6", "2.1500"},
   {"October 7", "2.1600"},
   {"October 8", "2.1600"},
   {"October 9", "2.1650"},
   {"October 10", "2.1975"},
   {"Oct 6 -10", "AVG: 2.1665"}};

Pick[sample, StringMatchQ[Last /@ sample, "*AVG*"], False]

or

Select[sample, StringMatchQ[Last@#, NumberString] &]
sample = {{"September 29", "2.2300"},
   {"September 30", "2.2075"},
   {"October 1", "2.1825"},
   {"October 2", "2.1400"},
   {"October 3", "2.1500"},
   {"Sep 29 - Oct 3", "2.1820-AVG"},
   {"October 6", "2.1500"},
   {"October 7", "2.1600"},
   {"October 8", "2.1600"},
   {"October 9", "2.1650"},
   {"October 10", "2.1975"},
   {"Oct 6 -10", "AVG: 2.1665"}};

Pick[sample, StringMatchQ[Last /@ sample, "*AVG*"], False]
sample = {{"September 29", "2.2300"},
   {"September 30", "2.2075"},
   {"October 1", "2.1825"},
   {"October 2", "2.1400"},
   {"October 3", "2.1500"},
   {"Sep 29 - Oct 3", "2.1820-AVG"},
   {"October 6", "2.1500"},
   {"October 7", "2.1600"},
   {"October 8", "2.1600"},
   {"October 9", "2.1650"},
   {"October 10", "2.1975"},
   {"Oct 6 -10", "AVG: 2.1665"}};

Pick[sample, StringMatchQ[Last /@ sample, "*AVG*"], False]

or

Select[sample, StringMatchQ[Last@#, NumberString] &]
Source Link
Chris Degnen
  • 31.3k
  • 2
  • 56
  • 109

sample = {{"September 29", "2.2300"},
   {"September 30", "2.2075"},
   {"October 1", "2.1825"},
   {"October 2", "2.1400"},
   {"October 3", "2.1500"},
   {"Sep 29 - Oct 3", "2.1820-AVG"},
   {"October 6", "2.1500"},
   {"October 7", "2.1600"},
   {"October 8", "2.1600"},
   {"October 9", "2.1650"},
   {"October 10", "2.1975"},
   {"Oct 6 -10", "AVG: 2.1665"}};

Pick[sample, StringMatchQ[Last /@ sample, "*AVG*"], False]