<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def step(self):
 """Single iteration of t-walk algorithm"""


        valid_proposal = False

        # Use x or xprime as pivot
        self._prime = (random() < 0.5)

        if self.verbose > 1:
            print_("\n\nUsing x%s as pivot" % (" prime" * self._prime or ""))

        if self._prime:
            # Set the value of the stochastic to the auxiliary
            self.stochastic.value = self.values[1]

            if self.verbose > 1:
                print_(
                    self._id,
                    "setting value to auxiliary",
                    self.stochastic.value)

        # Current log-probability
        logp = self.logp_plus_loglike
        if self.verbose > 1:
            print_("Current logp", logp)

        try:
            # Propose new value
            while not valid_proposal:
                self.propose()
                # Check that proposed value lies in support
                valid_proposal = self._support(self.stochastic.value)

            if not sum(self.phi):
                raise ZeroProbability

            # Proposed log-probability
            logp_p = self.logp_plus_loglike
            if self.verbose > 1:
                print_("Proposed logp", logp_p)

        except ZeroProbability:

            # Reject proposal
            if self.verbose > 1:
                print_(self._id + ' rejecting due to ZeroProbability.')
            self.reject()

            if self._prime:
                # Update value list
                self.values[1] = self.stochastic.value
                # Revert to stochastic's value for next iteration
                self.stochastic.value = self.values[0]

                if self.verbose > 1:
                    print_(
                        self._id,
                        "reverting stochastic to primary value",
                        self.stochastic.value)
            else:
                # Update value list
                self.values[0] = self.stochastic.value

            if self.verbose > 1:
                print_(self._id + ' returning.')
            return

        if self.verbose > 1:
            print_('logp_p - logp: ', logp_p - logp)

        # Evaluate acceptance ratio
        if log(random()) > (logp_p - logp + self.hastings_factor):

            # Revert s if fail
            self.reject()

        else:
            # Increment accepted count
            self.accepted[self.current_kernel] += 1
            if self.verbose > 1:
                print_(self._id + ' accepting')

        if self._prime:
            # Update value list
            self.values[1] = self.stochastic.value
            # Revert to stochastic's value for next iteration
            self.stochastic.value = self.values[0]

            if self.verbose > 1:
                print_(
                    self._id,
                    "reverting stochastic to primary value",
                    self.stochastic.value)

        else:
            # Update value list
            self.values[0] = self.stochastic.value