Skip to content

hasancatalgol/bayesian-statistics

Repository files navigation

Bayesian Analysis of Concrete Compressive Strength

This project applies Bayesian linear modeling techniques to the Concrete Compressive Strength Dataset from the UCI Machine Learning Repository. The primary objective is to analyze the relationship between material composition and compressive strength using probabilistic inference.


📘 Table of Contents


🏗️ Concrete Compressive Strength Dataset – Introduction

The Concrete Compressive Strength dataset is a widely used benchmark for regression modeling, sourced from the UCI Machine Learning Repository. It contains experimental data on how the proportions of different concrete ingredients affect the material’s strength. Below is a typical setup used in compressive strength testing of concrete cylinders:

Concrete Compression Test

Figure: Compression test configuration for a concrete cylinder
Source: ResearchGate - Compression Test Configuration

📊 Dataset Summary

  • Objective: Predict the compressive strength (in MPa) of concrete based on its ingredient mix.
  • Records: 1,030 observations
  • Features: 8 numerical input variables + 1 target
  • Target: Concrete compressive strength (MPa)

🧪 Features (Ingredients in kg/m³):

Feature Description
Cement Cement content
Blast Furnace Slag Supplementary cementitious material
Fly Ash Alternative cementitious material
Water Water content
Superplasticizer Chemical additive to improve flow
Coarse Aggregate Gravel or crushed stone
Fine Aggregate Sand
Age Curing time in days
  • Target: Strength – compressive strength of concrete after curing for 90 days.

📦 Environment Setup Guide (Windows 10/11)

This guide walks you through installing the necessary tools to run Bayesian models using PyMC with compiler and performance support on a Windows system.

✅ 1. Install TDM-GCC (C++ Compiler)

PyMC uses PyTensor as a backend that benefits from C compilation. You'll need a working g++ compiler.

➤ Steps:

  1. Download the "TDM-GCC x64 for 64-bit" installer. Download from here
  2. Run the installer:
    • Choose TDM-GCC 10.3.0-2.exe (default is fine)
    • Keep all components selected
    • Install to: C:\TDM-GCC-64\ (or leave default)

➤ Verify:

Open Command Prompt and run:

g++ --version

You should see something like:

g++ (tdm64-1) 10.3.0

✅ 2. Set Up Your Python Environment

We recommend using uv or venv to create a clean workspace.

➤ Create a virtual environment (with uv):

uv venv .venv

✅ 3. Install Required Python Packages

Install PyMC and performance libraries:

uv add pymc arviz numba pytensor

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages