We investigate the effect of star formation on turbulence in the Orion A and Ophiuchus clouds using principal component analysis (PCA). We measure the properties of turbulence by applying PCA on the spectral maps in (CO)-C-13, (CO)-O-18, HCO+ J = 1-0, and CS J = 2-1. First, the scaling relations derived from PCA of the (CO)-C-13 maps show that the velocity difference (delta v) for a given spatial scale (L) is the highest in the integral-shaped filament (ISF) and L1688, where the most active star formation occurs in the two clouds. The delta v increases with the number density and total bolometric luminosity of the protostars in the subregions. Second, in the ISF and L1688 regions, the delta v of (CO)-O-18, HCO+, and CS are generally higher ...