Heat flow does not have a direct effect on the Earth's magnetic field, but it can affect the Earth's interior, which in turn can affect the magnetic field.
The Earth's magnetic field is generated by the motion of molten iron in the outer core. This motion is driven by heat from the Earth's interior, which creates convection currents that generate electrical currents and a magnetic field. However, the heat flow itself does not affect the magnetic field directly.
That being said, the heat flow can affect the temperature and viscosity of the Earth's mantle and core, which can in turn affect the convection currents in the outer core and the strength and direction of the magnetic field. In addition, heat flow can cause changes in the Earth's rotation and shape, which can also affect the magnetic field.
Overall, the relationship between heat flow and the Earth's magnetic field is complex and not fully understood. Scientists continue to study this relationship in order to better understand the dynamics of the Earth's interior and the behavior of its magnetic field.