The invention provides polymers comprising pendent photochrome or near IR dye groups, as well as polymeric matrices made from these polymers, which can be used as or in association with a medical article. The polymers can be synthesized using methods that facilitate the preparation of medical articles having good biocompatibility. Exemplary polymeric matrices are in the form of lubricious coatings on medical devices, such as catheters. Visualization by irradiation of the photochrome or near IR dye can improve detection of the polymeric matrix on a device or in the body. This, in turn can improve aspects of a medical procedure, such as device insertion or matrix formation, as well as being useful for assessing the quality of the matrix.