Generic labels and R-groups
A generic label is a placeholder atom that stands for an unspecified part of a structure, such as the R in a general alcohol, R–OH. Molkit offers R for any substituent, X for a halogen or leaving group, Nu for a nucleophile, A, X, and E for the AXnEm notation of VSEPR, and others. A placeholder is not a carbon atom with a label, so a drawing such as H–X is never read as methane.

Placing a placeholder
Section titled “Placing a placeholder”The element column on the right edge of the canvas has an R button (tooltip “Generic substituent (R)”), an X button (tooltip “Generic leaving group (X)”), and a More ▸ button (tooltip “More generic groups…”) for the rest. Select one, then place it the same way you place an element; see Atoms and elements.
The More ▸ flyout lists these placeholders:
- A, R, X, Y, Z, Nu, E, LG, Ar, Het, M, Q, G, D
- Nu−, E+, and [M] as single entries
Each entry in the first group opens a submenu of indexed forms: the bare label, one and two primes (R′, R″), subscripts 1 to 3 (R1, R2, R3), and superscripts 1 to 3 (R1, R2, R3). The index is drawn as a true subscript or superscript next to the base letter.
Some placeholders share a symbol with a real element: Y (yttrium), Ar (argon, used here for “aryl”), and D (deuterium). Selecting them from the flyout marks them as placeholders.
You can also hover over an atom and type a placeholder label such as R, X, A, or R1. The atom becomes the same placeholder that the buttons create. The exceptions are Y and Ar: typed, they mean yttrium and argon, so select them from the flyout when you want the placeholder.
Converting an existing atom
Section titled “Converting an existing atom”To turn an atom into a placeholder, right-click it (one atom only) and select Atom > Convert to Generic Group. It keeps its custom label if it has one, and otherwise becomes R. To turn a placeholder back into carbon, right-click it and select Atom > Convert to Regular Atom. Each conversion is one undo step.
For example, to turn toluene into a general alkylbenzene, draw toluene, right-click the methyl carbon, and select Atom > Convert to Generic Group. The methyl becomes R, the ring keeps its implicit hydrogens, and the formula readout in the status bar goes blank because the structure no longer has a definite formula.
Files saved before version 0.13
Section titled “Files saved before version 0.13”In a file saved before version 0.13, a placeholder is a carbon atom with a text label. When you open such a file, a carbon labeled A, R, X, Z, Nu, E, LG, Het, M, Q, or G, or an R with an index (R1, R′, R1, R1), is converted to a placeholder. Labels that are also element symbols (Y, Ar, D) are not changed, so a real argon atom stays argon. A is on the list so that a drawn AX2E2 is read as a VSEPR formula, with no carbon at its center.
How Molkit treats placeholders
Section titled “How Molkit treats placeholders”A placeholder stands for something unspecified, so Molkit does not assign it chemical properties:
- It has no valence, formal charge, oxidation state, lone pairs, hybridization, or geometry, and it takes no implicit hydrogens. See Geometry and hybridization.
- Validation does not check its bonds or charge.
- A structure that contains a placeholder has no molecular formula or weight.
- A structure that contains a placeholder cannot be shown in the 3D viewer, which says that 3D is unavailable for generic groups because their geometry is undefined. It also gets no net dipole arrow.
The atoms around a placeholder are treated normally, so a carbon bonded to R still gets its implicit hydrogens.
Defining what an R-group stands for
Section titled “Defining what an R-group stands for”You can record which substituents a placeholder represents, for example “where R = Me, Et, Ph”. To edit one placeholder, right-click it and select Atom > Define R-Groups…. To edit every placeholder on the canvas (or the selected ones) at once, select Structure > Define R-groups….
The Define R-groups dialog has one card per placeholder atom:
- To add a substituent from the Molkit abbreviation library, type in the field “Add a substituent (type to filter: Me, Et, Ph…)” and select it. To add your own, type a SMILES string in “…or a custom SMILES” and click Add. A custom SMILES needs a
[*]at the attachment point to be usable as a full structure; without one, it is kept as a legend entry only. - The card shows a legend such as “where R = Me, Et” as you add members. One member is marked fixed; two or more are marked Markush family.
- Each placeholder atom has its own list. Two R atoms on the canvas are independent, even in the same molecule. When several atoms share a label, each card names the atoms it is bonded to, and ⌖ Locate selects that atom on the canvas.
- To store the lists, click Save. The whole save is one undo step.
The definitions are saved with the atom and written into SVG exports, so the Molkit Viewer and other programs that read the SVG’s chemistry data can show the legend or the individual family members.
Saving your own substituent
Section titled “Saving your own substituent”To add a substituent that is not in the library:
- Draw the substituent and select the whole fragment.
- Mark where it attaches in one of two ways:
- Draw a point-of-attachment squiggle across the attaching bond (see Squiggle tool), then right-click inside the selection.
- Without a squiggle, right-click the attaching atom itself.
- Select Selection > Save as R-Group Substituent.
- Give the substituent a name in the Save R-group substituent dialog.
The substituent then appears in the picker of the Define R-groups dialog. An R-group has exactly one attachment point, so a fragment with two squiggles is rejected.