The type of storage obviously depends on the sort of data you have. If it's just what you describe here then you can represent each journey as a string:
ABCB
DCDE
...
This well fits in a database, but of course such a list can be stored using any means, whatever is most easily available to you. You probably don't even need the entire list, an accumulated version might be sufficient, where you store each string exactly once, along with its count:
ABDC 177
DEA 2996
...
For such a table a database is appropriate, but its still simple enough to be stored in a plain file.
For examining the data you don't care about graph theory, rather read up on statistics and machine learning. The first thing you want to analyze is the correlation of the various places. You can do that using simple string operations, e.g. count the substrings "AD" to find out how often people go from A to D. And regarding the language: You want to calculate and visualize correlations, so maybe you pick something where that kind of stuff isn't too hard. This could be something specialized like Matlab or R, or something more general like Python/Matplotlib/scikit-learn. I don't know about Ruby.