Understanding and controlling crystal defects are essential in material engineering, the classical example being semiconductor devices created by a spatially well-controlled point defect distribution. [1] 2D defects include domain wall and grain boundaries. Polarization reversal in ferroelectric materials is essentially dictated by domain walls, whose dynamics can be highly complex. [2] The meaning of domains and domain boundaries for the polarization reversal in ferroelectrics is as crucial as the role of dislocations for the plasticity of metals. [3] Edge dislocations are classified as line defects which are frequently formed in strained thin films. In case the lattice mismatch exceeds the critical value, edge dislocations are formed. After exceeding the critical thickness, the lattice parameters relax to their natural values. A spatially extended displacement field accompanies dislocation, which in diffraction measurements is often seen as an asymmetric line shape. Determination of the strain and dislocation density are key parameters in semiconductor devices based on the epitaxial thin films.Crystal defects have a decisive role for the properties of thin films, yet their nondestructive structural characterization is challenging as the volume is characteristically small and the films are grown on a substrate. X-ray diffraction (XRD) is the prevailing route for nondestructively characterizing crystals and their defects. [4][5][6][7] XRD analysis relies on results extracted from bulk samples, single crystals, and powders. XRD data collected on thin-film samples possessing several layers are commonly considered to be consisting of noninteracting layers, the result being a sum of the patterns from each layer (or phase). To estimate the phase fractions, standard profile functions (e.g., Lorentz, Pearson or pseudo-Voigt) are commonly applied to model reflection intensities. The approach suits for the polycrystalline materials lacking features resulting from long-range order (e.g., subsidiary peaks in thin films) but is an overly coarse approach for highly ordered nanoscale structures. For instance, while asymmetric line shapes can routinely be fit by the standard line profiles, it is often hard to ascertain the origin of the asymmetry.In this article, another approach is taken to model defected films. The films, with spatially varying composition and structure, are taken as a single scattering unit. As the dimensions are small, between 10 and 100 nm, the scattered X-ray intensity profile is to an excellent accuracy determined by the sample, and no preassumed profile function is applied. We first simulate diffraction patterns from the homogeneous (Ni 0.42 Co 0.58 ) 2.22 Ti 0.39 O 3 film possessing atomic-scale disorder and second from hexagonal (Ni,Co) 3 O 3 thin films under compressive biaxial strain and edge dislocations. The situation contrasts to the case where no stress relaxation by dislocation has taken place. Thus, the simulations suit for cases where the standard measurements in which d-spacing for a chosen ...