Great question. The answer is no.
With all other factors equal, methane production in landfills is significantly higher than in a compost pile. This is because landfills by their nature cause organic matter to break down without oxygen, resulting in methane, when the same matter would produce mostly CO2 in a compost pile, because with compost oxygen is involved in the chemical change. Read more here.