Which of the following is the equation of a direct variation that has a constant of variation equal to -1/2?

A. y= x- 1/2
B. -1/2 y=x
C. y= -2x
D. y= -1/2x