Problem with profit and loss statement (wrong calculation)

Problem with profit and loss statement (wrong calculation)

Hi,

I have attached a screenshot of my profit and loss statement. (checked year to date option also)

This month statement it showing perfectly .
but Year to date column is adding Sales + cost of goods sold =gross profit .... instead of  Sales - cost of goods sold =gross profit


Am i doing anything wrong?