I'm not going to be able to give you a simple response to this.
The costs involved in putting up your own storage foods include equipment, supplies, know-how, and the value of your own time.
If you are generally a do-it-yourselfer and if you tend a large garden, you can cost-effectively dehydrate, freeze, and/or can your own foods. Know that, often, home-canned or dehydrated foods are not going to have the same long shelf life that can be had with quality commercially prepared storage foods.
But if you eat what you store and rotate your stocks, that should not be an issue.
For most folks, doing a little of both: home-canned/dried as time and energy allows, as well as purchasing commercial storage foods that are quick and easy to fill up your larder. No reason you have to do one or the other if you take a comprehensive view of preparedness.
So to determine cost savings to be had in doing it yourself? ... the biggest factors are:
1. Where are you going to acquire your food that you are going to can or dehydrate (are you going to raise it yourself or are you going to buy it from the grocer or a farmer's market, etc.?)
2. How big is the learning curve going to be for you and how much are you going to have to invest initially in equipment and supplies.
3. How much time do you have to invest in home preparation and what is your time worth?
Of course another factor to consider is how important it is to have the knowledge and ability to process foods for storage should the time come when that is necessary (not just as an option as it is today).
Last point to consider with commercial storage food that is legitimately good 25-years on the shelf ... it's pretty much a certainty that today's price for the MH food you purchase is going to be a bargain if you sit on it for a while given the steady inflation in food and other necessities. Not needing to rotate and replenish the food means your initial investment is appreciating in dollar value over time.
So--it has to be a personal decision ... based on your near-term budget, your outlook for the future, and your lifestyle.