trend code beginning // not complete