A temporal decomposition method for identifying venous effects in task-based fMRI


The spatial resolution of functional magnetic resonance imaging (fMRI) is fundamentally limited by effects from large draining veins. Here we describe an analysis method that provides data-driven estimates of these effects in task-based fMRI. The method involves fitting a one-dimensional manifold that characterizes variation in response timecourses observed in a given dataset, and then using identified early and late timecourses as basis functions for decomposing responses into components related to the microvasculature (capillaries and small venules) and the macrovasculature (large veins), respectively. We show the removal of late components substantially reduces the superficial cortical depth bias of fMRI responses and helps eliminate artifacts in cortical activity maps. This method provides insight into the origins of the fMRI signal and can be used to improve the spatial accuracy of fMRI.

Access options

Rent or Buy article

Get time limited or full article access on ReadCube.


All prices are NET prices.

Fig. 1: Schematic of the TDM method.
Fig. 2: TDM captures timecourse variation along a one-dimensional manifold.
Fig. 3: Early and late timecourses found by TDM.
Fig. 4: TDM decomposes brain activity patterns into early and late components.
Fig. 5: TDM outperforms a simple timepoint-based analysis.

Data availability

Materials related to this paper, including all datasets used, are available at https://osf.io/j2wsc/. Raw data in BIDS format63 are hosted at OpenNeuro at https://doi.org/10.18112/openneuro.ds002702.v1.0.1, whereas preprocessed data (that is, temporally and spatially corrected fMRI time-series data in surface format) are provided on the OSF site.

Code availability

Data were primarily analyzed using custom code written in MATLAB R2018a. The OSF site (https://osf.io/j2wsc/) includes an archive of the code used in this paper, sample data and scripts demonstrating the TDM method, and a link to a detailed video tutorial demonstrating the scripts and discussing the methodology and rationale therein. TDM source code is licensed under the BSD 3-Clause License, and is available at https://github.com/kendrickkay/TDM/ and on the executable platform Code Ocean (https://doi.org/10.24433/CO.4779366.v1)64.


  1. 1.

    Menon, R. S., Ogawa, S., Tank, D. W. & Ugurbil, K. Tesla gradient recalled echo characteristics of photic stimulation-induced signal changes in the human primary visual cortex. Magn. Reson. Med. 30, 380–386 (1993).

    CAS  PubMed  Google Scholar 

  2. 2.

    Turner, R. How much cortex can a vein drain? Downstream dilution of activation-related cerebral blood oxygenation changes. NeuroImage 16, 1062–1067 (2002).

    PubMed  Google Scholar 

  3. 3.

    Bianciardi, M., Fukunaga, M., van Gelderen, P., de Zwart, J. A. & Duyn, J. H. Negative BOLD-fMRI signals in large cerebral veins. J. Cereb. Blood Flow Metab. 31, 401–412 (2011).

    PubMed  Google Scholar 

  4. 4.

    Kay, K. et al. A critical assessment of data quality and venous effects in sub-millimeter fMRI. NeuroImage 189, 847–869 (2019).

    PubMed  Google Scholar 

  5. 5.

    Olman, C. A., Inati, S. & Heeger, D. J. The effect of large veins on spatial localization with GE BOLD at 3 T: displacement, not blurring. NeuroImage 34, 1126–1135 (2007).

    PubMed  Google Scholar 

  6. 6.

    Shmuel, A., Yacoub, E., Chaimow, D., Logothetis, N. K. & Ugurbil, K. Spatio-temporal point-spread function of fMRI signal in human gray matter at 7 Tesla. NeuroImage 35, 539–552 (2007).

    PubMed  PubMed Central  Google Scholar 

  7. 7.

    Cheng, K. Exploration of human visual cortex using high spatial resolution functional magnetic resonance imaging. NeuroImage 164, 4–9 (2018).

    PubMed  Google Scholar 

  8. 8.

    Ugurbil, K. What is feasible with imaging human brain function and connectivity using functional magnetic resonance imaging. Phil. Trans. R. Soc. 371, 20150361 (2016).

    Google Scholar 

  9. 9.

    Yacoub, E. & Wald, L. L. Pushing the spatio-temporal limits of MRI and fMRI. NeuroImage 164, 1–3 (2018).

    PubMed  Google Scholar 

  10. 10.

    De Martino, F. et al. The impact of ultra-high field MRI on cognitive and computational neuroimaging. NeuroImage 168, 366–382 (2018).

    PubMed  Google Scholar 

  11. 11.

    Dumoulin, S. O., Fracasso, A., van der Zwaag, W., Siero, J. C. W. & Petridou, N. Ultra-high field MRI: advancing systems neuroscience towards mesoscopic human brain function. NeuroImage 168, 345–357 (2018).

    PubMed  Google Scholar 

  12. 12.

    Lawrence, S. J. D., Formisano, E., Muckli, L. & de Lange, F. P. Laminar fMRI: applications for cognitive neuroscience. NeuroImage 197, 785–791 (2017).

    PubMed  Google Scholar 

  13. 13.

    Yacoub, E., Harel, N. & Ugurbil, K. High-field fMRI unveils orientation columns in humans. Proc. Natl Acad. Sci. USA 105, 10607–10612 (2008).

    CAS  PubMed  Google Scholar 

  14. 14.

    de Zwart, J. A. et al. Temporal dynamics of the BOLD fMRI impulse response. NeuroImage 24, 667–677 (2005).

    PubMed  Google Scholar 

  15. 15.

    Kim, J. H. & Ress, D. Reliability of the depth-dependent high-resolution BOLD hemodynamic response in human visual cortex and vicinity. Magn. Reson. Imaging 39, 53–63 (2017).

    PubMed  PubMed Central  Google Scholar 

  16. 16.

    Lee, A. T., Glover, G. H. & Meyer, C. H. Discrimination of large venous vessels in time-course spiral blood-oxygen-level-dependent magnetic-resonance functional neuroimaging. Magn. Reson. Med. 33, 745–754 (1995).

    CAS  PubMed  Google Scholar 

  17. 17.

    Siero, J. C. W., Petridou, N., Hoogduin, H., Luijten, P. R. & Ramsey, N. F. Cortical depth-dependent temporal dynamics of the BOLD response in the human brain. J. Cereb. Blood Flow Metab. 31, 1999–2008 (2011).

    PubMed  PubMed Central  Google Scholar 

  18. 18.

    Ogawa, S., Lee, T. M., Nayak, A. S. & Glynn, P. Oxygenation-sensitive contrast in magnetic resonance image of rodent brain at high magnetic fields. Magn. Reson. Med. 14, 68–78 (1990).

    CAS  PubMed  Google Scholar 

  19. 19.

    Havlicek, M. & Uludağ, K. A dynamical model of the laminar BOLD response. NeuroImage 204, 116209 (2020).

    CAS  PubMed  Google Scholar 

  20. 20.

    Handwerker, D. A., Gonzalez-Castillo, J., D’Esposito, M. & Bandettini, P. A. The continuing challenge of understanding and modeling hemodynamic variation in fMRI. NeuroImage 62, 1017–1023 (2012).

    PubMed  PubMed Central  Google Scholar 

  21. 21.

    Taylor, A. J., Kim, J. H. & Ress, D. Characterization of the hemodynamic response function across the majority of human cerebral cortex. NeuroImage 173, 322–331 (2018).

    PubMed  PubMed Central  Google Scholar 

  22. 22.

    Friston, K. J. et al. Event-related fMRI: characterizing differential responses. NeuroImage 7, 30–40 (1998).

    CAS  PubMed  Google Scholar 

  23. 23.

    Haacke, E. M. et al. 2D and 3D high resolution gradient echo functional imaging of the brain: venous contributions to signal in motor cortex studies. NMR Biomed. 7, 54–62 (1994).

    CAS  PubMed  Google Scholar 

  24. 24.

    Uludağ, K., Müller-Bierl, B. & Uğurbil, K. An integrative model for neuronal activity-induced signal changes for gradient and spin echo functional imaging. Neuroimage 48, 150–165 (2009).

    PubMed  Google Scholar 

  25. 25.

    Wandell, B. & Winawer, J. Imaging retinotopic maps in the human brain. Vision Res. 51, 718–737 (2011).

    PubMed  Google Scholar 

  26. 26.

    Wandell, B. & Winawer, J. Computational neuroimaging and population receptive fields. Trends Cog. Sci. 19, 349–357 (2015).

    Google Scholar 

  27. 27.

    Goodyear, B. G. & Menon, R. S. Brief visual stimulation allows mapping of ocular dominance in visual cortex using fMRI. Hum. Brain Mapp. 14, 210–217 (2001).

    CAS  PubMed  PubMed Central  Google Scholar 

  28. 28.

    Menon, R. S. & Goodyear, B. G. Submillimeter functional localization in human striate cortex using BOLD contrast at 4 Tesla: implications for the vascular point-spread function. Magn. Reson. Med. 41, 230–235 (1999).

    CAS  PubMed  Google Scholar 

  29. 29.

    Yu, X., Qian, C., Chen, D., Dodd, S. J. & Koretsky, A. P. Deciphering laminar-specific neural inputs with line-scanning fMRI. Nat. Methods 11, 55–58 (2014).

    PubMed  Google Scholar 

  30. 30.

    Yu, X. et al. Direct imaging of macrovascular and microvascular contributions to BOLD fMRI in layers IV-V of the rat whisker-barrel cortex. NeuroImage 59, 1451–1460 (2012).

    PubMed  Google Scholar 

  31. 31.

    De Martino, F. et al. Cortical depth dependent functional responses in humans at 7T: improved specificity with 3D GRASE. PLoS ONE 8, e60514 (2013).

    PubMed  PubMed Central  Google Scholar 

  32. 32.

    Fracasso, A., Luijten, P. R., Dumoulin, S. O. & Petridou, N. Laminar imaging of positive and negative BOLD in human visual cortex at 7T. NeuroImage 164, 100–111 (2018).

    PubMed  Google Scholar 

  33. 33.

    Heinzle, J., Koopmans, P. J., den Ouden, H. E. M., Raman, S. & Stephan, K. E. A hemodynamic model for layered BOLD signals. NeuroImage 125, 556–570 (2016).

    PubMed  Google Scholar 

  34. 34.

    Huber, L. et al. High-resolution CBV-fMRI allows mapping of laminar activity and connectivity of cortical input and output in human M1. Neuron 96, 1253–1263.e7 (2017).

    CAS  PubMed  PubMed Central  Google Scholar 

  35. 35.

    Lu, H., Golay, X., Pekar, J. J. & Van Zijl, P. C. M. Functional magnetic resonance imaging based on changes in vascular space occupancy. Magn. Reson. Med. 50, 263–274 (2003).

    PubMed  Google Scholar 

  36. 36.

    Markuerkiaga, I., Barth, M. & Norris, D. G. A cortical vascular model for examining the specificity of the laminar BOLD signal. NeuroImage 132, 491–498 (2016).

    PubMed  Google Scholar 

  37. 37.

    Marquardt, I., Schneider, M., Gulban, O. F., Ivanov, D. & Uludağ, K. Cortical depth profiles of luminance contrast responses in human V1 and V2 using 7 T fMRI. Hum. Brain Mapp. 464, 1155 (2018).

    Google Scholar 

  38. 38.

    Moerel, M. et al. Sensitivity and specificity considerations for fMRI encoding, decoding, and mapping of auditory cortex at ultra-high field. NeuroImage 164, 18–31 (2018).

    PubMed  Google Scholar 

  39. 39.

    Olman, C. A. et al. Layer-specific fMRI reflects different neuronal computations at different depths in human V1. PLoS ONE 7, e32536 (2012).

    CAS  PubMed  PubMed Central  Google Scholar 

  40. 40.

    Polimeni, J. R., Fischl, B., Greve, D. N. & Wald, L. L. Laminar analysis of 7T BOLD using an imposed spatial activation pattern in human V1. NeuroImage 52, 1334–1346 (2010).

    PubMed  PubMed Central  Google Scholar 

  41. 41.

    Woolrich, M. W., Behrens, T. E. J. & Smith, S. M. Constrained linear basis sets for HRF modelling using variational Bayes. NeuroImage 21, 1748–1761 (2004).

    PubMed  Google Scholar 

  42. 42.

    Poline, J. B. & Poldrack, R. A. Frontiers in brain imaging methods grand challenge. Front. Neurosci. 6, 96 (2012).

    PubMed  PubMed Central  Google Scholar 

  43. 43.

    Cheng, K., Waggoner, R. A. & Tanaka, K. Human ocular dominance columns as revealed by high-field functional magnetic resonance imaging. Neuron 32, 359–374 (2001).

    CAS  PubMed  Google Scholar 

  44. 44.

    Brainard, D. H. The Psychophysics Toolbox. Spat. Vis. 10, 433–436 (1997).

    CAS  PubMed  Google Scholar 

  45. 45.

    Pelli, D. G. The VideoToolbox software for visual psychophysics: transforming numbers into movies. Spat. Vis. 10, 437–442 (1997).

    CAS  PubMed  Google Scholar 

  46. 46.

    Stigliani, A., Weiner, K. S. & Grill-Spector, K. Temporal processing capacity in high-level visual cortex is domain specific. J. Neurosci. 35, 12412–12424 (2015).

    CAS  PubMed  PubMed Central  Google Scholar 

  47. 47.

    Fischl, B. FreeSurfer. NeuroImage 62, 774–781 (2012).

    PubMed  PubMed Central  Google Scholar 

  48. 48.

    Dale, A. M. Optimal experimental design for event-related fMRI. Hum. Brain Mapp. 8, 109–114 (1999).

    CAS  PubMed  PubMed Central  Google Scholar 

  49. 49.

    Charest, I., Kriegeskorte, N. & Kay, K. N. GLMdenoise improves multivariate pattern analysis of fMRI data. NeuroImage 183, 606–616 (2018).

    PubMed  PubMed Central  Google Scholar 

  50. 50.

    Kay, K. N., Rokem, A., Winawer, J., Dougherty, R. F. & Wandell, B. GLMdenoise: a fast, automated technique for denoising task-based fMRI data. Front. Neurosci. 7, 247 (2013).

    PubMed  PubMed Central  Google Scholar 

  51. 51.

    Hansen, K. A., Kay, K. N. & Gallant, J. L. Topographic organization in and near human visual area V4. J. Neurosci. 27, 11896–11911 (2007).

    CAS  PubMed  PubMed Central  Google Scholar 

  52. 52.

    Kay, K. N., David, S. V., Prenger, R. J., Hansen, K. A. & Gallant, J. L. Modeling low-frequency fluctuation and hemodynamic response timecourse in event-related fMRI. Hum. Brain Mapp. 29, 142–156 (2008).

    PubMed  Google Scholar 

  53. 53.

    Kay, K. N., Naselaris, T., Prenger, R. J. & Gallant, J. L. Identifying natural images from human brain activity. Nature 452, 352–355 (2008).

    CAS  PubMed  PubMed Central  Google Scholar 

  54. 54.

    Pedregosa, F., Eickenberg, M., Ciuciu, P., Thirion, B. & Gramfort, A. Data-driven HRF estimation for encoding and decoding models. NeuroImage 104, 209–220 (2015).

    PubMed  Google Scholar 

  55. 55.

    Friston, K. J., Josephs, O., Rees, G. & Turner, R. Nonlinear event-related responses in fMRI. Magn. Reson. Med. 39, 41–52 (1998).

    CAS  PubMed  Google Scholar 

  56. 56.

    Thompson, S. K., Engel, S. A. & Olman, C. A. Larger neural responses produce BOLD signals that begin earlier in time. Front. Neurosci. 8, 159 (2014).

    PubMed  PubMed Central  Google Scholar 

  57. 57.

    Zhang, N., Yacoub, E., Zhu, X.-H., Ugurbil, K. & Chen, W. Linearity of blood-oxygenation-level dependent signal at microvasculature. NeuroImage 48, 313–318 (2009).

    PubMed  PubMed Central  Google Scholar 

  58. 58.

    d’Avossa, G., Shulman, G. L. & Corbetta, M. Identification of cerebral networks by classification of the shape of BOLD responses. J. Neurophysiol. 90, 360–371 (2003).

    PubMed  Google Scholar 

  59. 59.

    Shmuel, A., Augath, M., Oeltermann, A. & Logothetis, N. K. Negative functional MRI response correlates with decreases in neuronal activity in monkey visual area V1. Nat. Neurosci. 9, 569–577 (2006).

    CAS  PubMed  Google Scholar 

  60. 60.

    Hastie, T. & Stuetzle, W. Principal curves. J. Am. Stat. Assoc. 84, 502–516 (1989).

    Google Scholar 

  61. 61.

    Wang, L., Mruczek, R. E. B., Arcaro, M. J. & Kastner, S. Probabilistic maps of visual topography in human cortex. Cereb. Cortex 25, 3911–3931 (2015).

    CAS  PubMed  Google Scholar 

  62. 62.

    Benson, N. C. et al. The human connectome project 7 tesla retinotopy dataset: description and population receptive field analysis. J. Vis. 18, https://doi.org/10.1167/18.13.23 (2018).

  63. 63.

    Gorgolewski, K. J. et al. The brain imaging data structure, a format for organizing and describing outputs of neuroimaging experiments. Sci. Data 3, 1–9 (2016).

    Google Scholar 

  64. 64.

    Kay, K. Temporal decomposition through manifold fitting. Code Ocean https://doi.org/10.24433/CO.4779366.v1 (2020).

Download references


We thank E. Margalit and N. Petridou for helpful discussions and L. Dowdle for assistance with preparing data in BIDS format. This work was supported by National Institutes of Health grant nos. P41 EB015894 (K.U.), P41 EB027061 (K.U.), P30 NS076408 (K.U.), S10 RR026783 (K.U.), S10 OD017974-01 (K.U.) and U01 EB025144 (K.U.), and the W. M. Keck Foundation (K.U.).

Author information




K.K. designed the experiment. R.-Y.Z. collected the data. K.K. and K.W.J. developed techniques and analyzed the data. K.K. wrote the paper. K.K., R.-Y.Z., K.W.J. and K.U. discussed and edited the manuscript.

Corresponding author

Correspondence to Kendrick Kay.

Ethics declarations

Competing interests

The authors declare no competing interests.

Additional information

Peer review information Nina Vogt was the primary editor on this article and managed its editorial process and peer review in collaboration with the rest of the editorial team.

Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Extended data

Extended Data Fig. 1 TDM results for the high-resolution gradient-echo datasets (D1–D12).

Magenta and cyan crosses indicate the early and late timecourses derived from the ICA-based procedure. The ICA-based procedure yields timecourses similar to TDM in some datasets (for example D4), but diverges substantially in others (for example D8).

Extended Data Fig. 2 TDM results for the alternative acquisition protocols (D13–D16).

To facilitate comparison, results obtained using the spin-echo and low-resolution protocols are placed next to results obtained using the high-resolution gradient-echo protocol.

Extended Data Fig. 3 Decomposition of brain activity patterns across datasets and acquisition protocols.

On the left are results obtained using high-resolution (0.8-mm) 7T gradient-echo (Datasets D1–D5). On the right are results obtained using high-resolution (1.05-mm) 7T spin-echo (Datasets D13–D14) and low-resolution (2.4-mm) 3T gradient-echo (Dataset D15–D16). These alternative acquisition protocols were conducted in the same subjects as the high-resolution gradient-echo protocol (correspondence indicated by arrows).

Extended Data Fig. 4 Detailed inspection of example vertices.

ac, Results for three surface vertices marked by arrows in Fig. 4. At the upper left are FIR timecourses with ribbon center and width indicating mean and standard error across two condition-splits. Dotted lines indicate the overall fit of the TDM model for each condition (reflecting a weighted sum of the Early and Late timecourses). At the lower left are canonical and TDM-derived timecourses. On the right are the three versions of the betas with bars and error bars indicating mean and standard error across six condition-splits and black arrows indicating peak eccentricity. Rainbow colors indicate stimulus eccentricity (1 = most foveal, 6 = most peripheral).

Extended Data Fig. 5 Response timecourses exhibit diverse proportions of early and late timecourses.

Each subplot depicts results for a single condition at a single vertex (Dataset D1). The left shows FIR timecourses (black, with lines and error bars indicating mean and standard error across two condition-splits) and the overall fit of the TDM model (purple). The right shows beta estimates (bars and error bars indicate mean and standard error across six condition-splits). To select which cases to show, we first identified vertices whose R2 under the TDM GLM is greater than 10%. We then examined the estimated betas and calculated their t-values (beta divided by standard error across condition-splits). We determined (i) all cases with a robust Early beta (t > 5) and a weak Late beta (absolute value less than 1/10 of the Early beta), (ii) all cases with robust Early and Late betas (t > 5) and where each beta is at least 9/10 of the other beta, and (iii) all cases with a robust Late beta (t > 5) and a weak Early beta (absolute value less than 1/10 of the Late beta). Finally, we randomly selected 20 cases from each of the three groups.

Extended Data Fig. 6 Quantitative assessment of BOLD amplitude estimates provided by TDM.

a, Histogram. The top plot shows distributions of BOLD amplitudes aggregated across Datasets D1–D12; the bottom plot shows results on a log scale and with a wider x-axis range. b, Kurtosis. Results are shown for individual datasets (thin lines, D1–D12) and the group average (thick black line). c, Standard deviation. d, Cortical depth profiles. The main plot shows the average depth profile observed in Datasets D1–D12, with ribbons indicating standard error across datasets; the inset plots show results for individual datasets (D1–D16), with ribbons indicating standard error across conditions. e, Reliability. Average correlation of betas across 6 splits of each dataset. f, Gradient-echo versus spin-echo. We re-plot results from panels D and E, directly comparing the gradient-echo and spin-echo datasets.

Supplementary information

Supplementary Information

Supplementary Notes 1–5, Discussion, Figs. 1–7 and References.

Reporting Summary

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Kay, K., Jamison, K.W., Zhang, R. et al. A temporal decomposition method for identifying venous effects in task-based fMRI. Nat Methods (2020). https://doi.org/10.1038/s41592-020-0941-6

Download citation


Sign up for the Nature Briefing newsletter for a daily update on COVID-19 science.
Get the most important science stories of the day, free in your inbox. Sign up for Nature Briefing