/ Published in: Bash
                    
                                        
For any text document this snippet generates an output file that looks like this:
30 m
29 por
29 aplicaci
27 modelo
27 datos
24 con
21 este
21 esta
                30 m
29 por
29 aplicaci
27 modelo
27 datos
24 con
21 este
21 esta
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
tr -sc 'A-Za-z' '\012' < text_file.txt | sort | uniq -c | sort -nr > output_ngram.txt
Comments
 Subscribe to comments
                    Subscribe to comments
                
                