perlance has asked for the wisdom of the Perl Monks concerning the following question:
I want to get chunks of the following texts( "True" cases under each "False" cases are part of the "False" cases Otherwise the False case has no True cases under it)GO:0002366 False GO:0002446 True GO:0002275 True GO:0043312 True GO:0006733 False GO:0019674 False GO:0043588 False GO:0055065 False GO:0055080 True
Can somebody help me doing this ? I'm trying to split the input file read by slurp mode, but not sure what /$pattern/, I would use: my @chunks = split(/($pattern)/, $data);#Chunk 0: GO:0002366 False GO:0002446 True GO:0002275 True GO:0043312 True #Chunk 1: GO:0006733 False #Chunk 2: GO:0019674 False #Chunk 3: GO:0043588 False #Chunk 4: GO:0055065 False GO:0055080 True
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Parsing block of texts
by kcott (Archbishop) on Apr 02, 2021 at 21:51 UTC | |
|
Re: Parsing block of texts
by tybalt89 (Monsignor) on Apr 02, 2021 at 21:26 UTC | |
|
Re: Parsing block of texts
by AnomalousMonk (Archbishop) on Apr 03, 2021 at 01:12 UTC | |
|
Re: Parsing block of texts
by Bod (Parson) on Apr 02, 2021 at 21:35 UTC |