I used this code but select all buttons like a checkbox
ListView.builder(
shrinkWrap: true,
physics: ClampingScrollPhysics(),
itemCount: sampleData.length,
itemBuilder: (context, index) => ButtonBar(
alignment: MainAxisAlignment.center,
children: <Widget>[
Radio(
groupValue: groupValue[index],
value: value[index][0],
onChanged: (newValue) => setState(() => groupValue[index] = newValue as int),
),
],
),
),
Please correct me where I am wrong
I want to create like this with dynamically and one selection at a time.

