Step 1 :Define the function \(f(x)\) as follows: \(f(x)=\sin (x)\) for \(x \leq \pi\) and \(f(x)=-4 \sin (x)\) for \(x>\pi\).
Step 2 :Calculate the integral of \(f(x)\) from 0 to \(\pi\), which is \(2\).
Step 3 :Calculate the integral of \(f(x)\) from \(\pi\) to \(2\pi\), which is \(8\).
Step 4 :Add the two integrals together to get the total integral from 0 to \(2\pi\), which is \(10\).
Step 5 :Final Answer: The integral of the function from 0 to \(2\pi\) is \(\boxed{10}\).