the number of stitches per inch depends on the weight of your yarn. There is a trick for wrapping the yarn around your needle to find the gauge but I don't know how to do it--if you look on the label of your yarn it'll usually tell you either how many stitches per inch or it will give it a weight such as fingering, worsted, bulky, dk, etc. There is a suggested yarn size for each weight of yarn. The best way to get the number of stitches you need is to first knit a swatch and then measure it. Then you can go up or down a needle size if needed. Since everyone's tension is different--the general guidelines won't work for everyone.
Check out this chart. I think you might find what you're looking for!
Hope this helps!