so i have a vector set of values and wanted to round all the values to the nearest positive, even integer. and all the values less then zero are rounded to zero. any idea on how to do this using an mfile?

# MATLAB: Manipulation of seperate vector values

manipulation

###### Related Question

- Vector/martix limit size
- Rounding Vector Entries with zeros after the decimal place to integers
- How to find the position of a real number in a vector
- How to replace all elements that are not even integers
- Find the nearest value
- How to get final value from iteration rather than block of numbers
- ELECTRIC POTENTIAL – How to speed up the code? (COMPLETE CODE INCLUDED)

## Best Answer