Forum

Please or Register to create posts and topics.

Color Coding All Related People

There is already an excellent query entitled Color Code by Consanguinity Degree but I decided I needed a slightly different color coding for relationships. I started out with the idea of clearing all colors and then color coding as red everyone in the database to whom I'm related. I used the Relate1 and Relate2 flags and after clearing all colors I simply color coded as red everyone whose Relate1 flag was non-zero or whose Relate2 flag was not zero. This was part of a project to weed out of my database people who are of little or no interest to me.

I quickly realized that I need to color code a few additional categories of people as follows.

Gray - people who I don't want to be touched by the script at all. These are people of interest who I don't ever want to delete from my database for whatever reason. The only way someone becomes color coded as gray is manually through the RM user interface.

Yellow - people who are not color coded. Step 1 of the script is to color code everyone as yellow who is not already gray. Yellow was chosen instead of black as the "not color coded" state in order to distinguish people who are deliberately without color code from people who are newly entered into the database.

Red - everybody who is still yellow and whose Relate1 or Relate2 flags are non-zero. These are the people who are related to me. Actually, I set relationships to one of my children before running my script to include my wife's relatives as being red.

Green - everybody who is still yellow and who is the spouse of someone who is red. If a person has multiple spouses, it only takes one spouse who is color coded red to get them color coded as green. There is an expectation that green people will show up in my narrative reports as the spouse of someone who is red.

Blue - everyone who is still yellow and who is the spouse of a person who is green.  I share Marriage and Divorce facts with both parties to the Marriage and Divorce. This causes the Marriage and Divorce events to show up in the individual timelines for each person in narrative reports in addition to showing in the timeline for the couple. Keeping blue people in my database rather than deleting them therefore has the effect of making the marriages and divorces between green people and blue people to show up in the timeline for green people in my narrative reports. The blue people themselves never show up in my narrative reports.

Purple - everybody who is still yellow and who is the parent of a person who is green. Everybody in my database who has parents has a Parents fact and the Parents fact is shared with the actual parents. Keeping the Purple people in my database rather than deleting them therefore means that the Parents fact shows up correctly for Green people in my narrative reports. The purple people themselves never show up in my narrative reports.

Brown - everybody who is still yellow and who is the child of a person who is purple. In other words, the brown people are the siblings of the green people. The brown people never show up in my narrative reports. Sometimes the brown people are of sufficient interest that I keep them in my database and sometimes they are not of sufficient interest and I delete them. But having them color coded as brown rather than yellow helps me to make an informed decision. I suspect that most users wouldn't bother with the brown color coding and would just leave these people yellow as people of very little interest.

Aqua - everybody who is still yellow and who is the spouse of a purple person. I'm really not sure why I care about this situation and leaving such people as yellow is probably fine. Aqua people effectively are the step-parents of the green people.

If you think about it, the basic scheme is that red is the  people I'm related to and green is spouses of the red people. All the other colors than gray or yellow are for people that are connected to the green people in some manner. So it's really just a matter of how far beyond the spouses of the relatives do I really want to go. My current goal is to get rid of all the yellow people. I could delete them from my database, and I'm doing so in most cases. I could color code them gray if I want to keep them for some weird reason, and I do so for very few cases. Or I could find a way to connect the yellow people to my red people.

Note that the "everyone who is still yellow and ...." criteria makes sure that the color coding in any particular step does not step on the color coding from any previous steps.

Uploaded files:

I had meant to delete the bit about color coding people with city directory facts from my script before uploading the script. But I'll just leave it in as an example of what can be done. If you choose to adapt this script for your own purposes, you can delete the city directory part if you wish or you can leave it in. It won't do anything unless you have a custom fact type called City Directory.

Thanks, Jerry. Your coding style is orderly, neat, tidy and well commented as usual. I note that your colour scheme is such that it works in both RM8 and prior versions, having chosen codes with identical names in both, despite some shifts in hue and saturation, viz. Colorcoding #RM8.

Interesting -- I did something similar.  I think allocated 4 colors for specific use then. See attached

Uploaded files: