Skip to Main Content
questions, ask us

Getting Started with Data Cleaning and OpenRefine

This guide is meant to introduce readers to the importance of data cleaning through a useful tool for working with "messy" data, OpenRefine.

How to Undo and Redo Edits

In the upper left-hand side of the screen, there is a tab that reads Undo/Redo:


Selecting that tab will allow you to see the changes you have made to your dataset since creating a new project.



The blue highlight will always be on the last change you made.


To undo multiple edits, select the final step you wish to preserve. For example, if we wanted to change the column heading back to "Facility," the 10th change in our record, we would select the 9th element. The edits you would like to undo will now be grayed out. Pay attention to the data in the interface, as it will revert to what it looked like prior to the edit.:



It is possible to undo a single step at once. Simply click on the edit made just prior. You would select #13 on the undo/redo list (the last change you would like to keep). You will notice that the "Date 1" and "Date 2" columns will re-merge.



To redo a change you just removed, simply re-select the final edit (edit #14 in the above example). You will see the data record reflect this change, and "Facility" will revert back to "FacilityName."

Extract and Apply Operation History

Something unique about OpenRefine is that you can copy and export your change history (every edit you have made to your data since creating a project). This is particularly useful if you are working on batches of files that will all require the same changes. To export your change history, look for the option just below the Undo/Redo tab, pictured below:



To copy your change history, select "Extract...." Note: If you were working on a new project and wished to apply a previously copied history, you would select "Apply...."

Once "Extract" is selected, a popup box will appear. This box, titled "Extract Operation History," contains a list of all edits that were made to your dataset. You can select (or deselect) so you're left with the steps you would like to copy. The edits themselves are represented on the right-hand side of this popup box, written as JSON (a data format).



You will copy and paste that JSON into a text editor (such as Notepad++) and save it for later use (to be Applied to another project).

To apply previously copied history, you would select "Apply..." and then paste the JSON code in the box that pops up called "Apply Operation History."

© University of Nevada Las Vegas