Replace response values or characters

673d23dd68cf08627e90e16be103471a

Updated at March 23rd, 2020

You can replace characters or entire response values by using the "replace" attribute in the JSON editor. 

Example

This is particularly useful for instances where you want to replace a certain character, word or phrase throughout all response values. In the example below a � character appears throughout some of the response values. Sometimes when datasets are imported into Protobi certain characters can appear this way.  

You can add the "replace" attribute in the JSON editor to insert a different character at every instance of "�".

This attribute can also perform a similar function as the Recode... dialog. You can use the "replace" attribute to replace entire values like changing "Whatever they want" to "anything". 

"replace" : {
    "�" : "/",
    "Whatever they want" : "anything"
},


The � character throughout Q24 has been replaced with "/" and the response value "Whatever they want" has been replaced as well. 



Was this article helpful?