A relation for Gromov-Witten invariants of local Calabi-Yau threefolds