# Using a Custom Color ForceField in FastROCS¶

Similar to the Shape Toolkit, a custom color forcefield can be used to compare color features beyond those captured with the default forcefield. To use a custom color forcefield, specify your forcefield during the initialization of your OEShapeDatabase OEShapeDatabase

Custom color forcefields in FastROCS are constructed the same way they are in the OEColorForceField class in the OEShape TK but are restricted to the following:

1. Interactions can only be between atoms of the same type
2. Interactions can only be favorable
3. Interactions can only be of type “gaussian”
4. user defined types are not permitted

in the following code example:

    cff = oeshape.OEColorForceField()
cff.Init(oeshape.OEColorFFType_ImplicitMillsDeanNoRings)
cff.ClearInteractions()
cff.GetType("donor"), cff.GetType("donor"), "gaussian", -1.0, range
)
cff.GetType("acceptor"), cff.GetType("acceptor"), "gaussian", -1.0, range
)
dbase = oefastrocs.OEShapeDatabase(cff)


a color forcefield is created that will only count interactions between pairs of acceptors and pairs of donors. The -1.0 indicates a favorable interaction, with standard weighting. 2.0 is the range of the color interaction in space.