Hi Team,
I need your help in creating a macro for anonymising data. The following steps will explain the step by step process of what the macro should be doing:
1. All the contents of each attribute (string) column should be anonymised in such a way that it should replace the real data with the header name. For example, if there is a country column with country names such as UK, US, India- then macro should replace the country names to Country_1, Country_2 and Country_3.
2. Similarly, it must recognise ID columns (for example- employee_ID) in the same manner as above.
3. For the measure/ value columns, we must randomise the numbers.
I'm attaching an excel file to showcase what result I would need from the macro for your reference. Please note that the macro should not be restricted to just this file and the columns mentioned in this file. There can be more/ less number of columns with different column names that the macro should be able to read.
Looking forward to your reply ASAP!
Solved! Go to Solution.
Hello @aishwarya_thilak I believe the attached solution should provide you with the desired outcome.
Let's take a look at your "ask":
@aishwarya_thilak wrote:Hi Team,
I need your help in creating a macro for anonymising data. The following steps will explain the step by step process of what the macro should be doing:
1. All the contents of each attribute (string) column should be anonymised in such a way that it should replace the real data with the header name. For example, if there is a country column with country names such as UK, US, India- then macro should replace the country names to Country_1, Country_2 and Country_3.
2. Similarly, it must recognise ID columns (for example- employee_ID) in the same manner as above.
3. For the measure/ value columns, we must randomise the numbers.
I'm attaching an excel file to showcase what result I would need from the macro for your reference. Please note that the macro should not be restricted to just this file and the columns mentioned in this file. There can be more/ less number of columns with different column names that the macro should be able to read.
Looking forward to your reply ASAP!
This looks rather urgent. I'd like to think that you're stuck with a specific challenge and not just asking us to do your work for you. Perhaps you're uncertain if the macro is a standard macro, batch macro or iterative macro? Maybe it is a combination of each? I'll assume that you've exhausted a search within or using Google of similar subjects and have reasons why posts like: https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Masking-Data-for-Security/td-p/29834 by @jdunkerley79 can't suffice to getting you started.
Have you checked the ideas https://community.alteryx.com/t5/Alteryx-Designer-Ideas/idb-p/product-ideas to see if there is a request for this functionality?
When I see terms like "Random" I wonder if you really want random. Someone's age could be 2,112,345,567 I suppose, but would you like that random age? There is so much ambiguity and so little thought to what the constraints of each field might require that I don't know where to start.
The ASAP request might require an URGENT title and maybe a few sprinkles of sugar on top.
I don't want to discourage members from posting their requests for help. I do want to encourage members to use community to assist them in their learning adventures.
Cheers,
Mark