У меня есть data.frame
с столбцами "a" и "b". Я хочу добавить столбцы с именем "высокий" и "низкий", которые содержат наивысший и самый низкий среди столбцов a и b.
Есть ли способ сделать это, не зацикливая строки в области данных?
edit: это для данных OHLC, поэтому высокий и низкий столбец должен содержать самый высокий и самый низкий элемент между a и b в одной строке, а не среди всех столбцов. извините, если это плохо сформулировано.