Co-occurrence
Co-occurrence is the presence of two or more items, events, or attributes within the same observation, context, or defined sequence, without necessarily implying causation.
AI-Powered Search
Co-occurrence is the occurrence of two terms within the same document or contextual unit.
- How it is used
- Finds related terms and queries for semantic search, query expansion, and knowledge-graph edge weighting.
- How deep it goes
- Explains document and user-based counts, PMI adjustment, composite ranking, and sparsity limits without deriving the full statistical theory.
- Examples
- Uses document terms, health-related products, shared-user queries, and product pairs such as “iphone 4s” and “iphone.”
- What you can do after
- Apply it via SQL and search analytics to generate related-term pairs and rank them with co-occurrence, PMI, or both.
Knowledge Graphs and LLMs in Action
Co-occurrence is the presence of two or more medical entities within the same sentence or textual context.
- How it is used
- Supports knowledge-graph use cases that combine unstructured medical text with structured ontology knowledge.
- How deep it goes
- Explains sentence-level pair generation, relationship aggregation, context retrieval, and ontology traversal, but not entity extraction itself.
- Examples
- Uses AIDS–Hepatitis, Zika virus–disease, and HPO disease–phenotype pairs with sentence context and ontology paths.
- What you can do after
- Apply via Cypher and APOC to create, rank, contextualize, validate, and explore medical-entity co-occurrences.
Read how Knowledge Graphs and LLMs in Action explains co-occurrence →
Natural Language Processing in Action, Second Edition
Co-occurrence is the occurrence of linguistic units together or in a shared sequence within a text.
- How it is used
- Uses neighboring terms to derive meaning, improve representations, learn embeddings, and support semantic search.
- How deep it goes
- Explains the shift from document-level counts to nearby context and self-supervised embeddings, but does not detail the training algorithm.
- Examples
- Uses short documents, nearby words, tokenized sentences, random text, and large machine-readable corpora as learning settings.
- What you can do after
- Evaluate how context-based counts improve language representations and support embeddings, topic analysis, and semantic search.
Read how Natural Language Processing in Action, Second Edition explains co-occurrence →
Related concepts
- embeddingused by · A numerical vector representation of an item or input that encodes features or relationships useful for computational tasks.
- structural causal modelcontrasts with · A structural causal model represents causal relationships among variables through equations that determine each variable from other variables and exogenous factors.
- co-occurrence networkused by · A co-occurrence network is a graph whose entities are connected when they appear together in a shared context.
- semantic analysisused by · Semantic analysis is the computational interpretation of the meanings of words, phrases, or statements.
- GloVeused by · GloVe is a word-embedding method that learns vector representations from global word-co-occurrence statistics across a corpus.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.


