Explore a estrutura dos textos
A versão 11 inclui uma nova e sofisticada ferramenta para analisar e visualizar textos, TextStructure.
Gere uma coleção agrupada de objetos de TextElement representando a estrutura gramatical de uma oração genérica.
In[1]:=
![Click for copyable input](assets.pt-br/explore-the-structure-of-texts/In_94.png)
TextStructure["The cat sat on the mat."]
Out[1]=
![](assets.pt-br/explore-the-structure-of-texts/O_62.png)
Mostre apenas legendas dos elementos gramaticais.
In[2]:=
![Click for copyable input](assets.pt-br/explore-the-structure-of-texts/In_95.png)
TextStructure["The cat sat on the mat.", "PartsOfSpeech"]
Out[2]=
![](assets.pt-br/explore-the-structure-of-texts/O_63.png)
Mostre as dependências gramaticais em uma representação gráfica.
In[3]:=
![Click for copyable input](assets.pt-br/explore-the-structure-of-texts/In_96.png)
TextStructure["The cat sat on the mat.", "DependencyGraphs"]
Out[3]=
![](assets.pt-br/explore-the-structure-of-texts/O_64.png)