X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=scpubgit%2Fstemmatology.git;a=blobdiff_plain;f=lib%2FText%2FTradition%2FAnalysis.pm;fp=lib%2FText%2FTradition%2FAnalysis.pm;h=85fe90a1bc02ddc85fd5f48c6ceaaecc653209a5;hp=1a3e7b19a5e14ba8b86b40869d6145719bfc53c5;hb=7b7abf10979385f65a15e873de8a6f41c610b50a;hpb=3e97c22cc5b43e7804cfae75998b45290353bf0e diff --git a/lib/Text/Tradition/Analysis.pm b/lib/Text/Tradition/Analysis.pm index 1a3e7b1..85fe90a 100644 --- a/lib/Text/Tradition/Analysis.pm +++ b/lib/Text/Tradition/Analysis.pm @@ -213,6 +213,8 @@ sub run_analysis { if( $rdg ) { $rdghash->{'text'} = $rdg->text . ( $rdg->rank == $rank ? '' : ' [' . $rdg->rank . ']' ); + $rdghash->{'is_ungrammatical'} = $rdg->grammar_invalid; + $rdghash->{'is_nonsense'} = $rdg->is_nonsense; } # Remove lacunose witnesses from this reading's list now that the # analysis is done @@ -753,8 +755,10 @@ sub analyze_location { $relation->{'annotation'} = $rel->annotation; } } - } - $rdgparents->{$p} = { 'label' => $prep, 'relation' => $relation }; + } + my $phash = { 'label' => $prep, 'relation' => $relation }; + $phash->{'text'} = $pobj->text if $pobj; + $rdgparents->{$p} = $phash; } $rdghash->{'reading_parents'} = $rdgparents;