Skip to content

Instantly share code, notes, and snippets.

@buzztaiki
Last active August 29, 2015 13:57
Show Gist options
  • Save buzztaiki/9512254 to your computer and use it in GitHub Desktop.
Save buzztaiki/9512254 to your computer and use it in GitHub Desktop.
ファイルにある名詞を抽出して眺めてみる
#!/bin/bash
cat - | mecab -N2 \
| grep -e '名詞' \
| grep -ve '名詞,.*\(数\|接続\)' \
| grep -ve '[a-zA-Z]' \
| awk -F'\t' '{print $1}' \
| sort | uniq -c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment