I have a variable called user_id in a string format, like: u:fwHX u:fwHX u:fwHX u:h_lx u:x_hi u:x_hi
They all start with a "u:" and then followed by a set of letters. I want to transform each unique user_id into a string in the following format:
user_id user_id u:fwHX U1 u:fwHX U1 u:fwHX U1 u:h_lx U2 u:x_hi U3 u:x_hi U3
This new user_id variable can only go from U1 until U123 (e.g U321, U312,U123.....). And i have to use the across and apply function to solve it. Thank you for the help!