The question is no less important when you start thinking of working for yourself as a photographer, but unfortunately there is no easy formula available to calculate your fees. There are however a number of factors that you have to take into account.
You will need professional quality equipment, and you need to factor in the cost of initial purchase and the cost of eventual replacement or upgrading.
Your premises costs affect your charges: rent, utilities, cleaning are just some of the charges you’ll need to meet. Even if you work from home, there are basic costs like phone and electricity bills that you need to cover.
There is then the real question, which is how much profit a photographer should be making. There are three key factors here: the rate currently being charged by photographers in your area (either geographical or professional specialty), your reputation and how much you want the work.
When you are starting out, you need to be mindful of the rates being charged by other photographers in your area. Unless these photographers are rank amateurs, producing low quality work, your charges need to be similar to theirs. The simple truth is that most customers will have a budget, and when they have a choice of two similar services, they will usually choose the cheaper. So you need to do some research to see who is working in your market, and what they charge.
Once your reputation is established, your prowess and skill widely recognised, word of mouth recommendations and the quality of your portfolio will mean that you have many requests for your work. At that stage you can review your charges, perhaps quoting on each project depending on how much you want the work.
Because this is the final factor to consider. I think we have all heard of builders or plumbers who submit very high quotes for the jobs they don’t really want to take on. A similar reasoning applies to working as a photographer: a high-status job which will give a wider audience to your work may be worth getting at any cost.