thomjur / PyCollocation

Python module to do simple collocation analysis of a corpus.
GNU General Public License v3.0
0 stars 1 forks source link

Creating twitter adapter #20

Open trutzig89182 opened 2 years ago

trutzig89182 commented 2 years ago

Habe mal ein bisschen an dem twitter adapter weiter gearbeitet und ihn nun auch einigermaßen zum Laufen bekommen. Wäre aber noch zu entscheiden, wie er in den Rest eingebunden wird. Sollte er z.B. auch eher unter tools? Oder mit in analysis.py?

trutzig89182 commented 2 years ago

Did a test run with my huge dataset and got a csv file back. But if it is realistic to offer a fixed module for twitter-data, as it will probably make sense to adapt and twitch the selection of texts for a dataset, for instance adding a language code as condition or something similar. In any case, I think that the collocations function is a very good basis for using python to do such an analysis also with twitter data.

trutzig89182 commented 2 years ago

One thing which is probably also related to #17. It could make sens to exclude urls from the calculation of collocates.

Also, it could make sense to ignore "RT" in case we don’t want to exclude retweets from the function, as this will be added to any "full_text" for a retweet.

thomjur commented 2 years ago

Ich hoffe, dass ich ab jetzt Zeit habe, etwas mehr wieder an dem Programm zu arbeiten. Ich habe den Adapter noch nicht ausprobiert, aber würde es nicht Sinn machen, den bei analysis.py einzubauen? Es gibt ja die Option doc_type.. vielleicht könnte man hier einen Type twitter hinzufügen? Weil sich dort auf den ersten Blick schon viele Sachen aus der analysis.py wiederholen. Ich schreibe mal auf Deutsch weiter, solange wir unter uns sind.^^

trutzig89182 commented 2 years ago

Ja, denke es ist sinnvoll das bei analysis.py einzubauen. Habe es erst mal noch getrennt gehalten, bis es einigermaßen verlässlich läuft. Ich bin nicht ganz sicher, inwiefern das am Ende nicht eher als Skript sinnvoll ist, weil es vielleicht doch recht stark an den eigenen Fall angepasst werden muss, aber das werden wir ja noch sehen.