in reply to Extracting Data from a second line
#!/usr/bin/perl use strict; use warnings; use Data::Dumper::Simple; read DATA, my $text, 163; #<- manually grabbed size of DATA just for t +his example my @matches = ($text =~ /red line.*?location\s+(\d+\.\d+\s+\d+\.\d+)/s +g); print Dumper(@matches); __DATA__ A red line is found at location 2.5 4.5 A Blue line is found at location 2.6 4.5 A red line is found at location 2.67 4.56 The red arc is found at location 2.5 4.5
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Extracting Data from a second line
by ikegami (Patriarch) on Feb 16, 2006 at 16:22 UTC | |
by kwaping (Priest) on Feb 16, 2006 at 16:34 UTC | |
by ikegami (Patriarch) on Feb 16, 2006 at 18:54 UTC | |
by kwaping (Priest) on Feb 16, 2006 at 19:25 UTC | |
by ikegami (Patriarch) on Feb 16, 2006 at 19:34 UTC | |
|