Replace space between ticks and format